chore: replace `mswDecorator` with `mswLoader`
This commit is contained in:
parent
ee8dcfa3ab
commit
5cde8de223
|
|
@ -7,7 +7,7 @@ import { FORCE_REMOUNT } from '@storybook/core-events';
|
||||||
import { addons } from '@storybook/preview-api';
|
import { addons } from '@storybook/preview-api';
|
||||||
import { type Preview, setup } from '@storybook/vue3';
|
import { type Preview, setup } from '@storybook/vue3';
|
||||||
import isChromatic from 'chromatic/isChromatic';
|
import isChromatic from 'chromatic/isChromatic';
|
||||||
import { initialize, mswDecorator } from 'msw-storybook-addon';
|
import { initialize, mswLoader } from 'msw-storybook-addon';
|
||||||
import { userDetailed } from './fakes.js';
|
import { userDetailed } from './fakes.js';
|
||||||
import locale from './locale.js';
|
import locale from './locale.js';
|
||||||
import { commonHandlers, onUnhandledRequest } from './mocks.js';
|
import { commonHandlers, onUnhandledRequest } from './mocks.js';
|
||||||
|
|
@ -122,7 +122,6 @@ const preview = {
|
||||||
}
|
}
|
||||||
return story;
|
return story;
|
||||||
},
|
},
|
||||||
mswDecorator,
|
|
||||||
(Story, context) => {
|
(Story, context) => {
|
||||||
return {
|
return {
|
||||||
setup() {
|
setup() {
|
||||||
|
|
@ -137,6 +136,7 @@ const preview = {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
loaders: [mswLoader],
|
||||||
parameters: {
|
parameters: {
|
||||||
controls: {
|
controls: {
|
||||||
exclude: /^__/,
|
exclude: /^__/,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue