yandex / reshadow

Markup and styles that feel right
https://reshadow.dev
Other
363 stars 15 forks source link

Errors in CodeSandbox for CRA with reshadow/macro #39

Open comerc opened 5 years ago

comerc commented 5 years ago

Edit frosty-varahamihira-hbo4f

if new project: reshadow/macro: require(...) is not a function

if shared project: reshadow/macro: Error: ENOENT: No such file or directory., '/empty.js'

antonk52 commented 5 years ago

Thank you for this and other issues. I will do my best to go over them, but it will probably be over the weekend.

lttb commented 5 years ago

Hi @comerc, thank you for the issue.

There is known problem on the Codesandbox with postcss on the babel transpiling. So there are two things to do to get it work with reshadow/babel or reshadow/macro:

1) create empty file empty.js in the root folder 2) add util as the dependency (because it is also required by some postcss plugins)

We've made some Codesanbox starters, that you can fork to play around with reshadow:

Just to note, you can also use reshadow on the Codesandbox without babel and macro, just the runtime version

comerc commented 5 years ago

Thanks!

comerc commented 5 years ago

@lttb CRA is work with reshadow@0.0.1-alpha.26, but it is not work with reshadow@0.0.1-alpha.65.

Edit reshadow-cra-i0ksj

reshadow/macro: Error: ENOENT: No such file or directory., '/events' Learn more: https://www.npmjs.com/package/reshadow