1.

Enable button through code after five seconds of page load in angular node js?

Answer»

Enable button through code after five SECONDS of page LOAD in angular node js?
To enable button after 5 seconds in angular we NEED to do some code change in .HTML and .ts file as give below. Once page is load button will automatically enable in five seconds.
(1)Below code need to add in .ts file

constructor() {
SETTIMEOUT(() => {
this.allowNewServer = true;
}, 2000);

and below is the image for above code


Angular TS File

(2)Below is the code need to apply on .HTML page to apply conditionon button as given below

[disabled]="!allowNewServer"

And below is the image for the same


Angular button



Discussion

No Comment Found