I have the following TS file:
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { FormsModule } from '@angular/forms'
import { AppComponent } from './app.component.js';
import { HeroComponent } from './hero.component.js';
import { DummyComponent } from './dummy.component.js';
import { MyComponent } from './my.component.js';
@NgModule({
imports: [BrowserModule, FormsModule],
declarations: [AppComponent, HeroComponent, DummyComponent, MyComponent],
providers: [],
bootstrap: [AppComponent, HeroComponent, DummyComponent, MyComponent]
})
export class AppModule { }
I want to replace the value in bootstrap array based on some conditions in UI.
bootstrap: [AppComponent, HeroComponent, DummyComponent, MyComponent]
All the following values
AppComponent, HeroComponent, DummyComponent, MyComponent
Should be populated through a global variable.
Could you please provide some light on this?