Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upstyles that are not injected do count for initial bundle size. #17672
Comments
|
We are having the same issue which breaks our deployments. The issue, for me, does not happen when I am on Broken
Not Broken
|
Command (mark with an
x)Is this a regression?
Unknown
Description
We generate different themes for our production build.
All are based on the same base styles with a different variables.scss.
We produce new files on each production build (which is handled by our ci/cd so build time is not that important).
the different styles are defined in the "styles" section of angular.json:
As you can see, the files are not injected.
In the production index.html I have verified that the files are not injected.
However, recently the budget exceeded for initial error caused our build to fail:
When we removed the different themes, the error dissapeared.
When looking at the build log it looks like the size of all the additional themes are included sum of the initial bundle size and thus are the cause of exceeding the limit (but in fact they are not, which is👍 )