checkbox storybook throwing cannot access before initialization error on local dev
Steps To Reproduce
yarn storybook, wait until build is complete
head to localhost:6006, should be directed to the first storybook Breadcrumb
click checkbox storybook or another component using checkboxes like FilterToggleSection
see error
Cannot access 'Checkbox' before initialization
ReferenceError: Cannot access 'Checkbox' before initialization
at Module.Checkbox (http://localhost:6006/common-components-Checkbox-Checkbox-stories.iframe.bundle.js:363:55)
at Module.Checkbox (http://localhost:6006/common-components-Checkbox-Checkbox-stories.iframe.bundle.js:518:100)
at registerExportsForReactRefresh (http://localhost:6006/vendors-node_modules_pmmmwh_react-refresh-webpack-plugin_client_ErrorOverlayEntry_js-node_mod-7eca0a.iframe.bundle.js:798:36)
at Object.executeRuntime (http://localhost:6006/vendors-node_modules_pmmmwh_react-refresh-webpack-plugin_client_ErrorOverlayEntry_js-node_mod-7eca0a.iframe.bundle.js:830:3)
at $ReactRefreshModuleRuntime$ (http://localhost:6006/common-components-Checkbox-Checkbox-stories.iframe.bundle.js:546:34)
at ./src/common/components/Checkbox/index.ts (http://localhost:6006/common-components-Checkbox-Checkbox-stories.iframe.bundle.js:559:2)
at options.factory (http://localhost:6006/runtime~main.iframe.bundle.js:635:31)
at __webpack_require__ (http://localhost:6006/runtime~main.iframe.bundle.js:28:33)
at fn (http://localhost:6006/runtime~main.iframe.bundle.js:293:21)
at ./src/common/components/Checkbox/Checkbox.tsx (http://localhost:6006/common-components-Checkbox-Checkbox-stories.iframe.bundle.js:370:85)
Describe the bug
checkbox storybook throwing
cannot access before initialization
error on local devSteps To Reproduce
yarn storybook
, wait until build is completelocalhost:6006
, should be directed to the first storybookBreadcrumb
FilterToggleSection
Expected behavior
checkbox storybook renders normally
Screenshots
Environments