Questions tagged as 'angular'

0
answers

Sluggishness in node ng serves when passing a certain time

I start my server with ngserve, over time the computer slows down until it becomes unusable, I have to close the node and open it again, there it goes for a while. Has anyone ever gone through this? Any idea what might be causing slowness?...
asked by 10.07.2018 / 17:39
2
answers

Change label class to active after angular http request

I have a component of the bootstrap design material that after an http request it is populated, the problem is that it does not change to the "active" class, taking the result of the photo. <divclass="md-form form-lg"> <...
asked by 10.07.2018 / 15:59
1
answer

Create policy for background-image

I have a directive for images, where if an image does not load I display a default image. Policy: import { Directive, Input, HostBinding } from '@angular/core'; @Directive({ selector: 'img[default]', host: { '(error)':'updateUrl(...
asked by 04.07.2018 / 16:51
1
answer

Table mat-table does not render in browser with Angular 6

In the browser debug I get this error (screenshot): Thisismypagehtml(test)<div><label>Nome:<input[(ngModel)]="operator.Name" placeholder="Nome"> </label> </div> <div> <label>Versão: <input [(...
asked by 03.07.2018 / 16:40
0
answers

Problem with the virtual keyboard of the "ngx-angular-material" angle together with the mask

I have a problem with the virtual keyboard of the angular "ngx-material-angular", when the input field has a mask and digit by the virtual keyboard of the angular mask is not respected, but when I type by physical keyboard the mask works perfectl...
asked by 02.07.2018 / 14:52
0
answers

How to use Observable to read another javascript file

In the company I work for I am forced to deal with some gambiarras and this is one more of them. It is as follows. I have an application in Angular 6 and I need to get the data from a .js file which is on a server that I do not have access to...
asked by 02.07.2018 / 06:49
0
answers

Lazy loading can not find my module in angle

This is trying to do lazy loading but is returning that my module is not found. My main app.routing.ts: import { NgModule } from '@angular/core'; import { Routes, RouterModule } from '@angular/router'; import { LoginComponent } from './co...
asked by 11.07.2018 / 03:34
1
answer

Angular 5, Map an array of Objects within another array of Objects

Well I'm trying to encapsulate my objects. The first object it maps to the first JSON array. export interface PraticarObject { id_assunto: number; nome_assunto: string; qt_exercicios_concluidos: string; conteudos: ConteudosPra...
asked by 27.06.2018 / 20:50
2
answers

How to get the return of a service inside an @component with angle 6

I made this table (omit the TR and TD's). <table mat-table [dataSource] = "dataSource" class="mat-elevation-z8"> If you create a mapped array, it works. Below my component ( commented lines, they work, a struck array ): import { Com...
asked by 04.07.2018 / 22:40
1
answer

Receive status of the http client request and login token in the angle

My backend api returns a token and a status, I need to save the token in the localstorage and redirect the user to the welcome screen if the status returned from api is 200. I tried something like: user.model.ts: export class Usuario{...
asked by 06.07.2018 / 00:47