Skip to content

Instantly share code, notes, and snippets.

@lydemann
Created Aug 29, 2022
Embed
What would you like to do?
// Fetch data included in main content on app initialization to reduce the time of Largest Contentful Paint (LCP)
providers: [
{
provide: APP_INITIALIZER,
useFactory: (state) => () => state.init(),
deps: [GlobalState],
multi: true
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment