Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Including JITCompiler for HTML Compiler breaks with AOT #23

Open
Mattnmoore opened this issue Aug 20, 2021 · 0 comments
Open

Including JITCompiler for HTML Compiler breaks with AOT #23

Mattnmoore opened this issue Aug 20, 2021 · 0 comments

Comments

@Mattnmoore
Copy link

Mattnmoore commented Aug 20, 2021

When I try to load the HTML Compiler component on my production build, I get the following error in console.log

 Error: Angular JIT compilation failed: '@angular/compiler' not loaded!
  - JIT compilation is discouraged for production use-cases! Consider AOT mode instead.
  - Did you bootstrap using '@angular/platform-browser-dynamic' or '@angular/platform-server'?
  - Alternatively provide the compiler with 'import "@angular/compiler";' before bootstrapping.

Do you know of a workaround for using this component with AOT and the build optimizer? I tried importing @angular.compiler at the top of main.ts and that didn't fix the issue.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant