There is one scenario in my project, Consider, I have one testDynamic component
@Component({
templateUrl: "./test-dynamic.html", // Need to override this file
styleUrls: ['./test-dynamic.css']
})
export class testDynamic {
constructor() { }
}
here need to check if an override1.html file is exists in override folder then load this file as templateUrl otherwise load the component default test-dynamic.html. Any idea how to achieve this.?
refer the following image for clearly understanding
https://stackoverflow.com/questions/31692416/dynamic-template-urls-in-angular-2%5B/link%5D – GSK Apr 23 '18 at 06:48