question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Angular 12 @Use statement causing slow compilation.

See original GitHub issue

Please see the link https://github.com/angular/angular-cli/issues/20713

The new theme API is really slow slow and problematic.

It seems related by the move to @use '~@angular/material' statements. My compilation time with CLI has increased 5x, i am also experiencing node memory issues. Reverting back to 11 does not have this issue.

I have engaged with the CLI team but it seems this issue is material related.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:14 (11 by maintainers)

github_iconTop GitHub Comments

5reactions
crisbetocommented, May 12, 2021

We noticed something similar while we were testing out the migration, but the issues usually went away once we migrated all remaining imports of @angular/material/theming to @angular/material. Can you check if you have any remaining usages of @import '~@angular/material/theming' in your codebase that might not have been caught by the migration?

2reactions
jelbourncommented, May 12, 2021

Got it, I likely misunderstood Keen yesterday.

I chatted with @crisbeto just now and he’s going to look into also cutting down the number of module resolutions in general.

For anyone coming to this issue: we’re hoping to land improvements in a patch release follow-up to 12.0.0.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Angular 12 Compilation is not immediately happening after ...
This is solved. It is caused because of serve configuration doesn't have the development mode configuration set in angular.json file.
Read more >
Ahead-of-time (AOT) compilation - Angular
Compiling your application during the build process provides a faster rendering in the browser. This guide explains how to specify metadata and apply ......
Read more >
Angular compiler options
When you use ahead-of-time compilation (AOT), you can control how your application is compiled by specifying template compiler options in the TypeScript ...
Read more >
Communicating with backend services using HTTP - Angular
Specifying the response type is a declaration to TypeScript that it should treat your response as being of the given type. This is...
Read more >
NG3003: Import cycles would need to be created to compile ...
So when building libraries using the "compilationMode": "partial" setting, any component that would require a cyclic import will cause this NG3003 compiler ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found