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

Make yarn install work with Yarn v2 #408

Open
danielattilasimon opened this issue Mar 19, 2021 · 0 comments
Open

Make yarn install work with Yarn v2 #408

danielattilasimon opened this issue Mar 19, 2021 · 0 comments

Comments

@danielattilasimon
Copy link
Collaborator

@DanWizard reported having trouble installing dependencies with Yarn v1 on Windows. Yarn v2 can install everything fine, but yarn start-dev-frontend has trouble loading some modules.

Failed to load config "react-app" to extend from.
Referenced from: C:\Users\***\liquity\packages\dev-frontend\package.json

After deleting eslintConfig from package.json:

C:/Users/***/liquity/.yarn/$$virtual/@emotion-react-virtual-cb0b3bb86b/0/cache/@emotion-react-npm-11.1.4-e22adbc3be-a75d76ba0b.zip/node_modules/@emotion/react/dist/emotion-element-4fbd89c5.browser.esm.js

Module not found: @emotion/react tried to access react (a peer dependency) but it isn't provided by its ancestors; this makes the require call ambiguous and unsound.

It seems whoever depends on @emotion/react is not providing its react peer-dependency. Yarn v2 is stricter about dependency loading, and won't load modules that are installed (indirectly) but not declared in package.json.

Yarnrc can be used to work around such bugs until they are fixed upstream: https://yarnpkg.com/configuration/yarnrc#packageExtensions.

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