Open Closed

NullInjectorError in console, Angular app couldn't load #702


2
hung.nguyen created
  • ABP Framework version: v4.0.0

  • UI type: Angular

  • DB provider: EF Core

  • Tiered (MVC) or Identity Server Seperated (Angular): no

  • Exception message and stack trace:

  • Steps to reproduce the issue: Just run the Angular app, it can not load. And in console you will see the error as in screenshot NullInjectorError: R3InjectorError(AppModule)[ApplicationModule -> ApplicationRef -> ApplicationInitStatus -> InjectionToken Application Initializer -> [object Object] -> ProfilePictureHandler -> ProfilePictureService -> RestService -> InjectionToken CORE_OPTIONS -> InjectionToken CORE_OPTIONS -> InjectionToken CORE_OPTIONS]: NullInjectorError: No provider for InjectionToken CORE_OPTIONS!

    Please help. I'm stuck for this, can not work any more.

    I did try adding InjectionToken to the provider list of AppModule but then it causes another error that can not fix. So I guess that is not the correct way.


5 Answer(s)
  • 0
    hung.nguyen created

    I did try clearing the cache, not work

  • 0
    edelivery created

    same problem with me

  • 0
    edelivery created

    Hi hung.nguyen I just delete folder nodemodule and clear cache, after that i using npm install and it work fine

  • 0
    hung.nguyen created

    hi, what cache do you mean here? Browser cache or npm cache? I tried as you said, clear the Browser cache, but still not work

  • 0
    edelivery created

    I deleted node module,package-locj.json, cache npm after that I'm using npm install anh start it ok