Added @ import to Webpack config, without needing a package#23020
Conversation
adding the condition, type error prevented
There was a problem hiding this comment.
@noviceGuru, thanks for taking the time to put together this pull request and help us improve the documentation. Appreciate it 🙏 ! From my end, I left a couple of items that require your attention so that we can merge this.
Additionally, while you're making the changes, do you mind checking the snippets, as they're failing the pretty-docs job to address it requires that you run the yarn pretty-docs script before committing.
Also, thanks for providing some additional context, and with that, I'm going to loop in a fellow maintainer that worked on the Next.js integration and see if this requires an additional pull request for the Next.Js framework documentation to factor in your issue. Sounds good?
@valentinpalkovic can you chime in on this when you have a moment? Appreciate it.
Description for aliasing configuration imporved, and type correction that was added to TS example, was added to JS version for accuracy and consistency.
jonniebigodes
left a comment
There was a problem hiding this comment.
@noviceGuru one small item for you that you left out. And apologize for not mentioning it earlier. Let me know once you've addressed it and I'll merge it.
Added `@` import to Webpack config, without needing a package (cherry picked from commit 829c084)
Added `@` import to Webpack config, without needing a package (cherry picked from commit 829c084)
Added `@` import to Webpack config, without needing a package (cherry picked from commit 829c084)
Added `@` import to Webpack config, without needing a package (cherry picked from commit 829c084)
Added `@` import to Webpack config, without needing a package (cherry picked from commit 829c084)
Added `@` import to Webpack config, without needing a package (cherry picked from commit 829c084)
Added
@importIt is the default in
NextJS 13and was not supported by storybook, while I was using it. The way I added it didn't need package to be installed or usedCorrected the type error in
config.resolveSince
config.resolvecan beundefined, usingconfig.resolve.extensionsran intoTypeScripterror. by adding a condition to the beginning of the line, I got rid of theTS Error.Worth to mention
I have a greenfield project in hand, using
NextJS13. After addingStorybookfor the first components, I ran into an error, thatStorybookdidn't recognize@imports that are default inNextJS13.The solution in the documentation didn't work for me, while the one I added worked just fine.