Skip to content

Commit

Permalink
fix: 第一打开 storybook 时,缺少 Suspense 的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
xyy94813 committed Jun 5, 2023
1 parent 0ba0312 commit ae26c24
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
export const decorators = [];
import React, { Suspense } from 'react';

export const decorators = [
(renderStory, context) => (
<Suspense fallback="loading">{renderStory({}, context)}</Suspense>
),
];
export const parameters = {};
export const globalTypes = {};
export const globalTypes = {};

0 comments on commit ae26c24

Please sign in to comment.