Closed moimael closed 6 years ago
👍 I am facing the exact same issue aswell.
We're also having the same issue. 😄
Looks like you are adding babel-plugin-require-context-hook/register
to .storybook/config.js
. request.context should be available if you're using webpack so you shouldn't need the register call. If you're trying to get it working with jest as I was then put the register call in jest_setup.js
as in https://github.com/storybooks/storybook/tree/master/addons/storyshots/storyshots-core#configure-jest-to-work-with-webpacks-requirecontext instead.
Although I personally do not use this with Storybook, this sounds exactly like you are trying to apply this plugin to a Webpack bundle instead of executing in Node. You don't need this plugin in Webpack; it's a polyfill for Webpack behavior in Node!
Thanks to @hazzadous for the link. If you still can't figure things out, you should probably ask someone from Storybook instead, as the problem is in your Storybook configuration, not within this plugin.
Hi,
I'm trying to use this plugin with storybook and I get a compile error each time. I followed the readme to set up the plugin.
Here is what I get: