mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-04 21:01:08 +08:00
parent
3a06253e01
commit
143324368c
@ -110,7 +110,7 @@ The default `tsconfig.json` that comes with CRA works great. If your stories are
|
||||
Change `config.ts` inside the Storybook config directory (by default, it’s `.storybook`) to import stories made with TypeScript:
|
||||
|
||||
```js
|
||||
// automatically import all files ending in *.stories.js
|
||||
// automatically import all files ending in *.stories.tsx
|
||||
const req = require.context('../stories', true, /.stories.tsx$/);
|
||||
|
||||
function loadStories() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user