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

Package no longer transpiled by Nuxt #50

Closed
rchl opened this issue Mar 19, 2022 · 2 comments
Closed

Package no longer transpiled by Nuxt #50

rchl opened this issue Mar 19, 2022 · 2 comments

Comments

@rchl
Copy link

rchl commented Mar 19, 2022

After f0241d4 Nuxt no longer transpiles this package when it's used on the client-side.

It's supposed to do that as it has ufo in transpile array by default: https://github.com/nuxt/nuxt.js/blob/777a4b7f5033c86c37cbd93008f3ca792e4af8bc/packages/webpack/src/config/base.js#L78-L78

It works with 0.7.9 version of the package but not 0.7.11.

I have verified that it's due to changing the browser export from index.js to index.cjs but not sure why as I'm not that familiar with babel/webpack. Manually renaming the file and reverting the export name in package.json to index.js makes it work again.

@rchl
Copy link
Author

rchl commented Mar 19, 2022

Oh, it's of course because the babel-loader is not set up for cjs extension in https://github.com/nuxt/nuxt.js/blob/777a4b7f5033c86c37cbd93008f3ca792e4af8bc/packages/webpack/src/config/base.js#L332-L332

@rchl
Copy link
Author

rchl commented Mar 19, 2022

Following up with a Nuxt issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant