Questions tagged [angular7]

Questions about Angular version 7, the web framework from Google. Use this tag for Angular questions which are specific to only version 7. Use tag Angular for any Angular questions which are not specific to an individual version.

0
votes
0answers
15 views

How can I get data from input type File

I am quite newbie in angular7 and I just trying to get data from an input type file in the html file. I am not getting it. I got the name and different specifications of the file, but not the proper ...
0
votes
1answer
23 views

I can't get current url when I receive a external-login url with token

I'm trying to get current url in Angular 7 but I don't know how is getting only the first "/" of full url. Attached image.
0
votes
1answer
55 views

Dynamic HTML containers

I need to create dynamic html, I have an input text in which I want to put a name and when pressing enter a container is created Title of container <span><i class="fas fa-users"></i&...
0
votes
0answers
12 views

Fetch the value of nested object from API response

If I have the following API response, how to fetch the value player using ngFor in angular 7?
0
votes
5answers
69 views

How to disable button in angular 7

I have an Angular7 app & using Reactive Forms Module for validation & forms. this is how my template looks like. <div class="row" [formGroup]="jobForm"> <div class="form-group" [...
0
votes
0answers
11 views

Unable to read query parameters after using custom RouteReuseStrategy

I have a component in my Angular 7 app which I wanted not to load it again and again. To achieve this purpose, I used the custom RouteReuseStrategy as mentioned in the answer here. Although using ...
0
votes
0answers
7 views

NgbModal respond very slow after using same modal again and again

I use a modalService ie. NgbModal to submit the Form on server. This form is having like 50 to 60 fields. When the form is submitted multiple times then after few submissions the website becomes ...
1
vote
0answers
10 views

Route Configuration for displaying list & details component together

I am unable to fetch the id using paramMap because it is coming null. Can someone help me to understand if there is anything wrong in the router configuration for displaying list & details ...
0
votes
0answers
14 views

How to get length of TypeScript Map<k, v>?(Error: Map.size gives undefined)

I have Map in my angular component as Map. I want to have the total number of entries in the map and length of match array as well. How do I do that? I've tried map.size and map.values().next()....
0
votes
1answer
32 views

How to validate multiple checkboxes in Angular 7? It should throw a message , that atleast one checkbox should be checked

<div class="form-group"> <div class="row mb-1"> <div class="col"> Select Functions from the list below:<br /> <div class="div-table mdle_rec"&...
0
votes
0answers
9 views

Applying angular material default theme to a specific component

Is it possible to apply the angular material default theme to a specific component only? I used @import "[email protected]/material/prebuilt-themes/deeppurple-amber.css"; in my component in style.css @...
-3
votes
0answers
38 views

Why ngSwitch is faster then ngIf?

A simple test shows that NgSwitch is faster than NgIf about 5-15%. Why is this so? Example: https://stackblitz.com/edit/angular-cv9mwy ngSwitch: <div *ngFor="let arr of array"> <div [...
-1
votes
1answer
26 views

Angular 7 server response not showing in list

I am very newbie on Angular. Currently I started working one sample. I am trying to get data from server and would like to show same in list. API response is coming in postman but it's not happening ...
1
vote
1answer
21 views

HTTP interceptor in angular 7 not adding headers

I am trying to set the auth token in http header by using the below code. It does not set the auth token in header. what am i Missing here? Tried the solution provided in below link but no luck with ...
0
votes
0answers
10 views

Ways to integrate the Jira issue collector with an Angular app?

I'm looking to create an Angular 7 app that utilizes the Jira issue collector to submit issues directly to their respective projects. When I build the app the way it is now, nothing happens. When I ...
0
votes
1answer
11 views

Angular 7 browser not reflecting the changes made in the code

I am using Angular 7. Till last night it was working fine but since this morning whatever change I am making in the code is not showing in the browser. I have tried clearing browser history installing ...
0
votes
0answers
9 views

Get value of dynamic ngmodel

I create a textbox with dynamic ngmodel now i want to access the value in ts file. <div *ngFor="let num of ['1','2','3']; let i=index"> <input id="qtd{{num}}" **[(ngModel)]="qtd[num]"** ...
-1
votes
0answers
20 views

Disable Change Detection for NGRX Actions (Angular 7)

Initial Situation Let's suppose I use this function to dispatch an action: this.store.dispatch(Action(payload)); It is located in the app.component.ts and is called often (depending on the user ...
-1
votes
0answers
9 views

How to use other locale in ng2-pdfjs-viewer

My system allows multiple locales, ideally the pdfjs would use the same as the user configured, but I could not figure out how this setting is done in pdfjs, can anyone help?
3
votes
1answer
63 views

Creating dynamic forms from api response in angular7

I have created a component to create dynamic forms using angular reactive forms. When I try to use the component to create form fields in another component depending on the response from my API. The ...
0
votes
0answers
12 views

How to insert data with promise in Angular7 using ng-crud-table

I try to make Crud operation using ng-crud-table following the demo project but stuck on POST, DELETE and PUT request how to utilize these with service which provided in the sample code I am ...
0
votes
0answers
19 views

Keep class when dragging - Drag and Drop Angular7

I need that when dragging an element of the left to the containers of the right the element conserves its background-color to be able to differentiate it. And if it is "Therapists" it is above all ...
0
votes
0answers
9 views

Disable Reactive form button If edited value is same as original value

I have an angular 7 reactive form consisting of 3 input fields and a submit and cancel button. I want to enable the buttons only when the value in the input fields has been changed to a value ...
0
votes
0answers
9 views

Mat-tab-group headerPosition=“below” - But where is content?

I make a material design with tabs. But i cant show some content after the toolbar? Like this: https://stackblitz.com/angular/mklavlygkqd?file=app%2Ftab-group-header-below-example.html This is my ...
0
votes
1answer
8 views

i crated new project but there was a problem while it is running - events.js:183 throw er; // Unhandled 'error' event

i am using angular 7 and i created new app by using cmd code "ng new testapp" it was install successfully but couldn't run there was an error "events.js:183 throw er; // Unhandled 'error' event"
0
votes
1answer
10 views

Storing user's data permanently in a div

My question is about angular 7, so I have made this simple quiz coed from "StackBlitz" and I want when the user finishes the quiz, his or her answers should be stored below the quiz? How can i do that?...
1
vote
0answers
26 views

How do I connect Firebase Real-Time Database to my Angular 7 app? With CRUD operations

I'm trying to connect my Real-Time Database to my Angular 7 application. And I'm trying to code my Angular 7 app to be able to use the CRUD operations to update the database. I've added my Real-...
1
vote
1answer
17 views

How to delay http responses on errors in Angular 7

I am working on an Angular7 project and have some issues about error handling on http requests. Here is my Login Component with two functions export class LoginComponent implements OnInit, ...
0
votes
0answers
33 views

Angular material expansion panel losing background when expanded

I am using angular 7 and material expansion panel in my project. In css I changed the color of the header both on and without hover. When I expand the panel the hover is working but when I leave the ...
-4
votes
1answer
32 views

I have 3 components on my home page how i can call it in routing in Angular 7

I have 3 components on my home page how I can call it in routing in Angular 7 because in angular routing only one component can be called with route path. Can I import other components in one ...
0
votes
0answers
15 views

How to pass an image captured by a webcam using Angular7 to the Azure faceAPI

I am very new to Angular 7 and I wanted to create a very basic app that would capture your image through the webcam and send it over to the AzureAPI to get your age. However, I have been getting the ...
0
votes
1answer
13 views

Generate seperate build file for a particular component in angular 7

I am going to develop a very large application using Angular 7 Framework. I have created a blank angular workspace using ng new angular-app --create-application=false And in this workspace I have ...
-1
votes
0answers
13 views

compiler.js:2430 Uncaught Error: Unexpected value 'GoogleMaps' imported by the module 'AppModule'. Please add a @NgModule annotation

I want to add maps in my ionic 4 app page. I want to mark current location of user. For that I installed cordova plugin add cordova-plugin-googlemaps --variable API_KEY_FOR_ANDROID="...
0
votes
0answers
10 views

how to post submitted reactive form data into table created in another component in angular 7?

The data is already displayed in console.But ,i m unable to display console or submitted form data into table of another component.The form has name,address,gender and submit button.so the table ...
-2
votes
1answer
31 views

401 Unauthorized : WWW-Authenticate: Bearer

I've seen similar threads to this issue, but I had no luck solving it. LogIn worked successfuly but when I try to GET data of the user loggedIn in my home page I receive this error 401 Unauthorized ...
0
votes
1answer
23 views

Ionic 4 Image upload using Angular HTTP

I use Ionic 4 and Angular 7 with PHP as Back-end. I am trying to upload files (images/videos/PDFs/audio). Is there a general way to send it. I tried to send image using camera plugin it returns the ...
1
vote
2answers
35 views

How do I check if the user has scrolled down (or crossed ) to a particular element (based on id) in Angular7?

How do I check if the user has scrolled down (or crossed ) to a particular element (based on id) in the browser so that I can check the condition and assign class name dynamically in angular 7?
0
votes
2answers
37 views

Uncaught (in promise): TypeError: this.Form is undefined error in angular 6

When I am trying to call one .ts file from another using .Form the following error is occurring Uncaught (in promise): TypeError: this.Form is undefined The file that has an error in it have ...
0
votes
0answers
14 views

After importing bootstrap into app.module.ts, unexpected token < error araises

installed ngx-bootstrap in angular-seed after that i have imported in app.modules.ts and added additional package in project.config.ts then started app using npm start it return unexpected token <...
-1
votes
1answer
24 views

In Angular, how to refer to / inject a singleton object in a constant

I know how to do dependency injection in a component class. i.e. constructor(private staticDataService: StaticDataService) However, in Angular 7, am I able to inject the singleton staticDataService ...
0
votes
0answers
17 views

How to pass Authorization Httpheaders into the CORS in the php file

i'm using angular7. storing currentUser data into the localStorage. after that integrated AuthInterceptor and injected into the app.module.ts file //after login getting user data {"result":"success","...
0
votes
0answers
5 views

How to import only part of Ionic 4's modules?

My app is made with Ionic 4 and Angular Material 7. Most of the UI components are Angular Material's components. So there must be many Ionic's components being imported from IonicModule which are ...
0
votes
0answers
6 views

Is there any work around to fix the issue Module parse failed:(Angular7)

ERROR in ./node_modules/core-js/modules/es6.regexp.exec.js 1:3 Module parse failed: Unexpected character ' ' (1:3) You may need an appropriate loader to handle this file type. (Source code omitted for ...
0
votes
0answers
43 views

Angular 7 Http Post Request - Subscribe only catching OPTIONS response not the actual response

I am sending a post request to upload a file from my angular 7 front end. The network console on chrome shows that it is sending an OPTIONS request first before sending my post request. I can also see ...
-2
votes
0answers
22 views

Is there any way I can build an angular and php app on server?

I have an FTP server and I want to build my angular app on the server and use phpmyadmin on my FTP server. I have tried searching the ways but what I got was only that deploy (upload /dist folder) a ...
0
votes
0answers
7 views

Angular 7 interceptor not adding headers in request

I am using angular 7 and here is my interceptor code import { Injectable } from '@angular/core'; import { HttpInterceptor, HttpHandler,HttpHeaders, HttpRequest, HttpEvent } from '@angular/common/http'...
-1
votes
0answers
34 views

How to use Lazy routes for Angular 7 Universal

I had stuck on deploying Angular 7 website as I am not aware of how to make the lazy routes available with Angular Universal which should be SEO capable. I am using Angular 7 as a part of client-side ...
0
votes
1answer
52 views

Why Angular HttpClient response is null?

My Environments: Shop RestController : Spring Boot on localhost laptopn ubuntu 18:04 ShopService: Angular HttpClient on localhost desktop pc windows 10 Problem: My get request via HttpClient got ...
0
votes
0answers
13 views

Http Request from Angular7 to Codeigniter :: how to send API key, getting “{”status“:false,”error“:”Invalid API key “}” responce

I'm making an HTTP request from angular service to codeigniter controller, i'm not getting CORS error because I've added following code in the constructor for my controller header('Access-Control-...
0
votes
2answers
27 views

router navigation not working after login success

angular router not working after login success. I have Auth Module Under Auth module i have login components I have Admin Module Under Admin module i have 3 components 1).admin component 2).admin-...