Most voted "angular" questions
Angular is a framework created by Google for the development of web applications. Use this tag for questions about syntax, errors, doubts, among others. Not specific to a version. For Angularjs-related issues (1.X) use the Angularjs tag.
Learn more…2,063 questions
Sort by count of
-
0
votes1
answer1154
viewsAngular validate password field with Formgroup
I have the following code: TS code: ... onRegisterForm: FormGroup; ngOnInit() { this.onRegisterForm = this._fb.group({ nome: ['', Validators.compose([ Validators.required ])], email: ['',…
-
0
votes1
answer62
viewsHow to work with current German at Angular 4?
My goal is to have an implementation that the user starts typing is shown in real time a validation message counting the characters being typed, and I do not know how to do this, I know there is the…
-
0
votes1
answer46
viewsHow do I release my ' + ' button only when selecting an item from the list?
I have a problem in ngFor, because I want to enable the + button only when an item in the list is selected. But my widget option does not accept Event bind (click). Can you help me? <div…
-
0
votes0
answers49
viewsInject component into another component
I would like to know, if I can inject a component into another component, I have a function within a component and when I go to do something into another component, I would like to call that…
-
0
votes0
answers87
viewsHow to take the value of the variable within a Function in IONIC?
getListTodayOrders(): InterfaceOrders { const url = 'http://oneqbackend.herokuapp.com/api/listas'; this.http.get(url).subscribe((data: InterfaceOrders) => { this.data_return = data; console.log('…
-
0
votes2
answers85
viewsWhy is the H1 tag not generating a new line?
$scope.html = [{ "name": "teste", "data": [{ "tag": { "name": "h1", "text": "Titulo 1", "colValue": "" } }, { "tag": { "name": "text", "colValue": "col-xs-4" } }, { "tag": { "name": "h1", "text":…
-
0
votes0
answers31
viewsAjax (Angularjs) returning HTML from the page itself
I am using Codeigniter to retrieve the database data. Controller: <?php defined('BASEPATH') OR exit('No direct script access allowed'); class Welcome extends CI_Controller { public function…
-
0
votes2
answers138
viewsAngular interpolation not updated
I’m learning angular and I’m having a difficulty, the program is very simple has a textInput and a paragraph, which if typing in the textInput should appear in the paragraph. onKeyUp(evento: any){…
-
0
votes1
answer90
viewsIncrement Array with filter
I need to increment the item this.order[i].nome_servicein the variable this.result only when you click the checkbox as well as decrement when unchecked. orders = [ {id_service: "1", id_empresa: "9",…
-
0
votes1
answer1332
viewsAngular - Browser does not update after code changes
I’m using Angular (version 4) and my code changes don’t make an automatic build of the application. The default is to make changes to the code and already give the automatic build, as get Started…
angularasked 6 years, 8 months ago Guilherme Nass 939 -
0
votes1
answer202
viewsShow template according to user status
I am developing a system but I am having difficulties in the authentication part, or better, not necessarily in the authentication part, but rather in the part to show or not certain content…
-
0
votes2
answers287
viewsCopy button in textarea in Ionic
I’m trying to create a button that makes a CTRL+C in textarea, with javascript, it is possible to make a select() in the document.getElementById, and after the one document.execCommand('copy'), but…
-
0
votes1
answer31
viewsIonic problem 4 . present();
I am studying Ionic and I am in the Ionic CLI version : 4.12.0, I am facing a problem in my home constructor, when using the present() method in my loading variable presents the following error:…
-
0
votes0
answers307
viewsAngular 2 and material.angular.io
Example with the name "Table retrieving data through HTTP", https://material.angular.io/components/table/examples. But I switched to search the database. The information comes from the database.…
-
0
votes1
answer432
viewsHow to implement a bootstrap menu in an Angular project?
I put the following code and it didn’t work; <nav class="navbar navbar-default"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand"…
-
0
votes1
answer219
viewsHow to store an ion-input value in a variable and pass it on the route?
Imagine the following scenario in Ionic 4: I have an ion-input for the user to enter a Ticket number. I want to store this value in a variable in the component class and then use it to pass as route…
-
0
votes0
answers161
viewsOperator '>' cannot be Applied to types 'Boolean' and 'number'. ng build --Prod
I wonder what might be going on in this case. Every time I try to run the command ng build --prod this error appears saying that it is in the HTML file of one of the components on line 76, follows…
-
0
votes1
answer473
viewsIncrement Ionic data 3, Angular, Typescript
I would like to know how to increase the expiration date of a purchase. Example: the person made a purchase, and put the due date for the day 30 March, then the date of the second installment would…
-
0
votes1
answer126
viewsdifficulty to list data in angular 4 datatable
As the title says, I cannot load the database records into the Primeng datatable. No error messages appear on the Visualcode console, no error messages appear on the internet browser console, no…
-
0
votes0
answers45
viewsHow to remove the form name from the url at angular 7?
When I direct to a component at the angle, its name is available at the page address for example http://localhost/#/form-login Would there be some way that the component name would be hidden?…
-
0
votes1
answer1782
viewsImplementing Search with Angular 4
Look at the picture The user will type in the title field to perform a search in the table, but an error appears in the browser console The error message informs that the problem is in the search…
-
0
votes2
answers132
viewsMy value is replaced in Localstorage
I’m trying to add data to Localstorage through a form. However, it always replaces the value and does not appear the key I had determined (it is as 1). In this code snippet is when it takes the user…
-
0
votes1
answer360
viewsSeparate Array within Object
I have an array inside an object, I would like to know how to separate the items service_name and service_value. I don’t know if there’s a way to do this in html itself... pedido{id_pedido:"17",…
-
0
votes1
answer52
viewsUpload gif before data reaches page
I am bringing the data from the server through an NGFOR with pipe async but I would like to show a gif of loading until the data arrives, it takes about 3 seconds for the data to appear on the…
-
0
votes2
answers745
viewsAngular Eventemitter 4 does not work
I have a.service Profile that broadcasts an event for two components that don’t communicate. By clicking on the Profile Component link, it triggers the…
-
0
votes1
answer1603
viewsHow to use Moment.js with date from an input date?
I have the following form: <form name="formConsultaPeriodo"> Data Inicial <input class="form-control dataIni" type="date" name="dataIni" ng-model="consulta.dataInicial" required /> Data…
-
0
votes1
answer239
viewsAngular 7 - Power Tooltip on prime-table buttons
I am using the prime-table, along with the tooltip, and would like the tooltip message to be customized for my system. Ex: The edit button will display the "Edit user" message in the user table and…
-
0
votes1
answer749
viewsFormat an html form input as a currency
Please someone can help me, I’m not able to format an input as currency. <label for="saldoInicial">Saldo Inicial</label> <input type="number" format="currency" precision="2"…
-
0
votes1
answer417
viewsMaintain application status at Angular 7
I need to maintain the state of a component even after navigating from one route to another or after closing the application. I have a component where displays the duration of a call and the…
-
0
votes2
answers791
viewsFormgroup does not take default values
The proposal of this page would be to update my database, however, the form is only considering the changed values, that is, if any field is not changed in the form this will be changed to ''…
-
0
votes0
answers32
viewsHow to Fileupload Video at Angular 4?
I created a API Java to fileupload any file, it’s something simple, it just takes any selected image and sends to C: images, I’m using with Angular 4, my goal is to make this implementation with…
-
0
votes1
answer39
viewsMultiple validators in the form
I have the code seguints With the version of angular.json so: "@angular/cli": "~6.0.0" When trying to use a more current version it looks like this: With the angular cll so: "@angular/cli": "1.2.7",…
-
0
votes1
answer54
viewsregex.test is not a Function
I need to apply a mask that formats both landline and phone. I tried to: <input [pattern]="customPatterns" type="text" class="form-control" id="numero" name="numero"…
-
0
votes2
answers3232
viewsHow to implement an Alert in the angular HTML page?
As you can see in the figure below the Angular component is composed of component, css and Html in the midia-cadastrar.component.html file tried to put a simple implementation of Alert as you can…
-
0
votes1
answer80
viewsCreating and using component at angular 2
I created this component to show success message or not. import { Component } from '@angular/core'; import { MatSnackBar } from '@angular/material'; @Component({ selector: 'app-snack-bar',…
-
0
votes3
answers4107
viewsHow to implement Bootstrap 4 in Angular CLI
I’m having trouble using Bootstrap with the Angular CLI. I am using ng-bootstrap and I am following all the recommendations of the site, but without success, someone knows how to use? installation…
-
0
votes0
answers161
viewsError in VSCODE console
I have this mistake in VSCODE. ERROR in src/app/paginas/arquivo/arquivo-form/arquivo-form.component.ts(93,20): error TS2339: Property 'total' does not exist on type 'HttpEvent<{}>'. Property…
-
0
votes1
answer741
viewsChanging parameters to Modal
I’m having trouble passing parameters to my Modal, I would like to present the data of the selected tuple, I was able to isolate the value properly (atestei by the console.log), however, this same…
-
0
votes1
answer37
viewsButton to delete form if only it is not filled
I have a button that add new locations Forms. I would like to know how to delete the form if you have added it will not be filled. I created this link to delete the fields. <div class="col-12…
-
0
votes1
answer88
viewsError 415 - Upload files
pom.xml <dependency> <groupId>commons-fileupload</groupId> <artifactId>commons-fileupload</artifactId> <version>1.3.3</version> </dependency> Angular,…
-
0
votes1
answer386
viewsHow to change the application theme in Ionic 4
I’m using Ionic 4 and I’m having a hard time changing the theme to dark. In Ionic 3, I was only in the document scss variables. and made the change: de @import "ionic.theme.default"; para @import…
-
0
votes0
answers27
viewsWhat to do with the authentication token when it arrives at the front?
I’m developing a site with Laravel on the server (API) and angular on the front. To authenticate a user in the system, I recover the credentials (email and password) and, if the user exists and the…
-
0
votes2
answers696
viewsAngular2-text-Mask
How to apply a phone mask where it adapts to a landline and mobile phone, using the Angular2-text-mask? I read the documentation and saw that you can do with function, but as I am using formGroup, I…
-
0
votes1
answer68
viewsName a given id field inside a @foreach
<?php counter = 0 ?> @foreach($buildings as $building) <?php $var1 = counter; $counter = counter + 1; ?> <input type="checkbox" id="campo{{counter}}"…
-
0
votes4
answers993
viewsHow to pass/receive data to components via routing
In my app-routing-module I will reuse the same component for four different routes, but I need to know a way to differentiate these components. Currently my app-routing passes a title property on…
-
0
votes0
answers39
viewsMy Lightbox module that I inserted in Angular does not work, how to do it?
Well I installed this Lightbox module with the command npm install lightbox2 --save according to the website: lightbox so far so good. After I put the paths in the angular file-cli.json as examples…
-
0
votes1
answer52
viewsApplying the principle of single liability in methods using subscribe
Consider the following class: export class TesteComponent { //... public onSubmit() { this.checkA(); } private checkA(): void { this.service.checkA(value) .subscribe(response => { if(response) {…
-
0
votes1
answer35
viewsWhat is the use of $ in an expression that executes a pipe in a property in Angular?
In the tutorial written by Jen Looper for Nativescript website it demonstrates a code that before the pipe is preceded by the symbol $ as below: <ScrollView> <StackLayout>…
-
0
votes1
answer214
viewsHow to wait for the result of a Firestore query?
My problem is this: I have a component that will list some categories, example: categories: Observable<any[]>; ngOnInit() { this.categories = this.categoryService.getAll(); } In the service I…
javascript firebase typescript angular firebase-databaseasked 6 years, 7 months ago Isaias Tavares 291 -
0
votes2
answers68
viewsCreate an Angular filter with smart table
I’m starting now with Angular, and I don’t have much knowledge, I wonder if someone with more knowledge can help me make an Angular filter with Smart Table. Ex: I have a text box that will retrieve…