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

addIfAbsent does not compare modules correctly #2

Closed
moarcaffeine opened this issue Dec 5, 2019 · 3 comments
Closed

addIfAbsent does not compare modules correctly #2

moarcaffeine opened this issue Dec 5, 2019 · 3 comments

Comments

@moarcaffeine
Copy link
Contributor

This is related to #1.

I can indeed run your example but I get complaints about @babel/core being missing as a peer dependency of all the dependencies in neutrino-typescript.

Consequently it would seem Babel is not operational in this state. However, when you add @babel/core you will receive the error about duplicate plugins and be unable to proceed to the web landing:

Details

Failed to compile.

./src/index.tsx
Module build failed (from ./node_modules/.pnpm/registry.npmjs.org/babel-loader/8.0.6_@babel+core@7.7.4+webpack@4.41.2/node_modules/babel-loader/lib/index.js):
Error: Duplicate plugin/preset detected.
If you'd like to use two separate instances of a plugin,
they need separate names, e.g.

....

I traced down the issue and it looks like the fix is relatively simple. I'm attaching a PR. Hope it helps. Thank you for working on this!

@davidje13
Copy link
Owner

davidje13 commented Dec 7, 2019

I think the main problem here was version mismatches; I have updated all the dependency versions and things seem to be happy (no complaints about @babel/core that I can see). You should never need to explicitly bring in @babel/core in a neutrino project as I understand things (jest, node, and react presets all include it as a non-peer dependency, for example)

I've merged your suggested fix too, since it seems reasonable, but I made a few changes in line with the comments I added to the PR. Can you check that it works for you now?

@davidje13
Copy link
Owner

@moarcaffeine is this OK to close now?

@davidje13
Copy link
Owner

Closing this issue because this appears to be OK and haven't heard back for nearly a year. Happy to re-open if this is still a problem for anybody.

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

2 participants