Category "angular5"

Angular 8 : What is the best way to store some temp data to transfer between the components

I need to store some temporary data to communicate between the component. (say the data is JSON). We have a lot of ways like LocalStorage, SessionStorage, Servi

How to detect browser close event or tab close event in angular 6+?

I have written @HostListener in my AppComponent Class to detect browser close or tab close. I have written this code but it is not working. Kindly help me unde

Angular 5 Material mat-sidenav toggle not working

I'm trying to get the sidenav to work using the official open/close example. I'm new to Angular, so I'm not sure how everything is supposed to work, but for o

Form validation error message show on submit in angular

I am trying to validate form in angular 6 but not working. My code is in stackblitz. How to validate that form and how to show error message? https://stackblitz

How can I make dynamic url to external site in angular5?

When I'm trying to make link like this: <a [href]="getUrl()">click me</a> getUrl() { return this.domSanitizer.bypassSecurityTrustUrl

Angular 5 - Copy to clipboard

I am trying to implement an icon that when clicked will save a variable to the user's clipboard. I have currently tried several libraries and none of them have

No provider for $WebSocket angular5 with

I have some application which uses websockets, for that I was using angular2-websocket in my angular5 application. I keep getting following errors: StaticInj

Angular 5 - how to limit change detection only to component scope?

How to configure Angular component not to trigger change detection for the whole application but only for the component itself and his children? Working exampl

Angular Reactive Forms AddControl Causes ExpressionChangedAfterItHasBeenCheckedError When Using PatchValue

I wanted to be able to build up a reactive form using components, but not set it all up in a single parent component. So I created the intial FormGroup and pas

How to handle image upload in angular 5 Tiny MCE component?

I am using TinyMCE editor in angular my angular 5 project, and want to handle image uploads, which I am currently not able to do. Here is my current code: <e

Angular5 use external component in Lazy loaded Module

I has LazyModule which I load lazy, and another one ModuleA. I need to use component Module-A-Component inside LazyModule. How can I access this external compon

Hiding Azure CDN url

Is there any way to hide the Azure CDN Url in the browser. We have developed the application using ASP.Net Core 2 with Angular 5, also is there any helper class