We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug When I wrote a switch component in storybook. He would report an error。 Such as:
ERROR in ./src/components/Switch/switch.tsx Module build failed (from ./node_modules/babel-loader/lib/index.js): SyntaxError: /Users/antd-with-ts/src/components/Switch/switch.tsx: Unexpected token, expected "(" (90:10) catch (__react_docgen_typescript_loader_error) { }try { 89 | // @ts-ignore > 90 | switch.displayName = "switch";
To Reproduce Steps to reproduce the behavior:
interface SwitchProps{} export const Switch:FC<SwitchProps> = (props) => { return <>something</> } export default Switch
in switch.stories.tsx
storiesOf("Switch component", module).add('Switch", () => <Switch />);
This component will report errors when used in storybook
Expected behavior Should nothing go wrong
Screenshots If applicable, add screenshots to help explain your problem.
Code snippets If applicable, add code samples to help explain your problem.
System Please paste the results of npx sb@next info here.
npx sb@next info
Additional context Version of packages I use
The text was updated successfully, but these errors were encountered:
Related: #11419
Sorry, something went wrong.
thanks
closing as dupe to #11980
No branches or pull requests
Describe the bug
When I wrote a switch component in storybook. He would report an error。
Such as:
To Reproduce
Steps to reproduce the behavior:
in switch.stories.tsx
This component will report errors when used in storybook
Expected behavior
Should nothing go wrong
Screenshots
If applicable, add screenshots to help explain your problem.
Code snippets
If applicable, add code samples to help explain your problem.
System
Please paste the results of
npx sb@next info
here.Additional context
Version of packages I use
The text was updated successfully, but these errors were encountered: