Tried changing soultion from here . It works fine, but if you change the template to templateUrl in the component that needs to be dynamically loaded, you will get the error message: "No implementation of ResourceLoader was provided. Unable to read URL ...".
@Component({ selector: 'string-editor', templateUrl: 'app/parts/string.html', //using template URL instead of inline template here }) export class StringEditor { ... }
Live example on plunker . Any ideas how to fix this?
Do not use COMPILER_PROVIDERSbecause it overrides ResourceLoader.
COMPILER_PROVIDERS
ResourceLoader
Compiler ( RuntimeCompiler):
Compiler
RuntimeCompiler
@Inject(Compiler) protected compiler: Compiler
ApplicationModule :
ApplicationModule
imports: [ ApplicationModule, BrowserModule, DynamicModule.forRoot() // singletons ],
Plunker
Source: https://habr.com/ru/post/1655608/More articles:Unable to play this video error - javaDynamic href base link with webpack - angularSwift 3 - How to write functions without initializers, such as new UIColors? - functionКак изменить цвет текста c3.js - cssGet an instance of MyFirebaseInstanceIDService activity - androidConfigure Cordova fastlane xcode 8 profile - iosAsp.net ID - Reset cookie and session on iis recycle (reload) - c #Ошибка условного вызова обратного вызова ActiveRecord - rubyКак сделать все экземпляры в Java что-то - javaIn Android, how to decode a UTF-8 encoded string? - androidAll Articles