You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I added a custom class extending Date to my project adding some helper functions but storybook considers every occurence where I use it as a simple Date and throws a <helper function> is not a function. This problem does not occur when I start the CRA app with the Calendar directly.
The problem still occurs when the storybook is built and served with npx serve. I also tried reinstalling all dependencies.
Also casting the Date to a CustomDate as I call the helper function (with (new CustomDate(myDate)).helperFunction() or (myDate as CustomDate).helperFunction()) still cause the error to trigger.
The text was updated successfully, but these errors were encountered:
We’re cleaning house! Storybook has changed a lot since this issue was created and we don’t know if it’s still valid. Please open a new issue referencing this one if:
Describe the bug
I added a custom class extending Date to my project adding some helper functions but storybook considers every occurence where I use it as a simple Date and throws a
<helper function> is not a function
. This problem does not occur when I start the CRA app with the Calendar directly.To Reproduce
$ yarn; yarn storybook
localhost:6006
Calendar>Default
You can start the working CRA app with
$ yarn start
Expected behavior
The calendar should be displayed with no error.
System
Additional context
The problem still occurs when the storybook is built and served with
npx serve
. I also tried reinstalling all dependencies.Also casting the Date to a CustomDate as I call the helper function (with
(new CustomDate(myDate)).helperFunction()
or(myDate as CustomDate).helperFunction()
) still cause the error to trigger.The text was updated successfully, but these errors were encountered: