Open
Description
Describe the bug
When using storybook 8 version in angular, the APP_INITIALZER dosen't work.
The problem looks the same as the issue before.
I tried to correct it by referring to what was on this link, but it still doesn't run.
I modified 'preview.ts' as below in this stackblitz project, but it doesn't work.
const preview: Preview = {
parameters: {
actions: { argTypesRegex: '^on[A-Z].*' },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/i,
},
},
},
decorators: [
moduleMetadata({
providers: [
{
provide: APP_INITIALIZER,
useFactory: () => {
console.log('APP_INITIALIZER!!!!');
},
multi: true,
},
],
}),
],
};
export default preview;
Reproduction link
https://stackblitz.com/edit/github-rkffss-81zfge
Reproduction steps
- Go here https://stackblitz.com/edit/github-rkffss-81zfge
- and modify preview.ts
const preview: Preview = {
parameters: {
actions: { argTypesRegex: '^on[A-Z].*' },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/i,
},
},
},
decorators: [
moduleMetadata({
providers: [
{
provide: APP_INITIALIZER,
useFactory: () => {
console.log('APP_INITIALIZER!!!!');
},
multi: true,
},
],
}),
],
};
export default preview;
- I can't see the
APP_INITIALIZER!!!!
log
System
Additional context
No response