-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Docs site cleanups #30488
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
Docs site cleanups #30488
Conversation
Updates the docs site to the latest version of Angular.
The docs site was loading the data of all the examples up-front through an eager import which was bringing in ~170kb of JavaScript which isn't necessary for the initial load. These changes refactor the various call sites so that they load the example data asynchronously.
Drops the `@angular/animations` module from the docs site since it's no longer necessary. This removes another ~70kb from the initial bundle.
Removes (almost) all of our `@NgModule` usage in the docs site by replacing their usages with standalone imports.
Runs the inject migration over the docs site to make it consistent with the rest of the repo.
Reworks the docs site to remove all remaining `@NgModule` usages.
01170fa
to
8d329bb
Compare
Fixes that the formatting check was catching some files incorrectly, like pnpm lock file.
|
||
bootstrapApplication(MaterialDocsApp, { | ||
providers: [ | ||
prefersReducedMotion ? provideNoopAnimations() : provideAnimations(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My plan is to handle reduced motion centrally from Material, instead of relying on the animations module for it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Includes a bunch of cleanups for the docs site (see below) that ended up removing 230kb from the initial bundle.
build: update the docs site to latest Angular
Updates the docs site to the latest version of Angular.
fix(material-angular-io): remove docs data from critical path
The docs site was loading the data of all the examples up-front through an eager import which was bringing in ~170kb of JavaScript which isn't necessary for the initial load. These changes refactor the various call sites so that they load the example data asynchronously.
fix(material-angular-io): remove animations dependency
Drops the
@angular/animations
module from the docs site since it's no longer necessary. This removes another ~70kb from the initial bundle.refactor(material-angular-io): use standalone imports instead of modules
Removes (almost) all of our
@NgModule
usage in the docs site by replacing their usages with standalone imports.refactor(material-angular-io): switch to inject function
Runs the inject migration over the docs site to make it consistent with the rest of the repo.
refactor(material-angular-io): remove remaining modules
Reworks the docs site to remove all remaining
@NgModule
usages.build: narrow down prettier file set
Fixes that the formatting check was catching some files incorrectly, like pnpm lock file.