Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zustand/shallow and zustand/middleware are not transpiled to cjs #46

Closed
timkindberg opened this issue Jul 12, 2019 · 3 comments
Closed
Labels
bug Something isn't working

Comments

@timkindberg
Copy link

I'm getting errors because zustand/middleware.js and zustand/shallow.js have non-supported syntax in them.

There is a .cjs.js file for each but then I have to import from 'zustand/middleware.cjs' which feels a bit weird, but it's a successful workaround.

It seems with additional non-main entries like these, they do not have the convenience of specifying main and module in the package.json like the main entry has. So the safest bet would probably be to have their .js file be the lowest common demoninator, commonjs.

I'm not sure these two entries need to be exported as anything but commonjs.

@drcmda
Copy link
Member

drcmda commented Jul 12, 2019

that makes sense, i'll reconfigure rollup

@drcmda drcmda added the bug Something isn't working label Jul 12, 2019
@with-heart
Copy link

Can confirm that the rollup changes for this were completed in #65 and build outputs work as expected

@JeremyRH
Copy link
Contributor

Great! Thank you for the feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants