You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yarn 2 - Styled components - Module not found: A package is trying to access a peer dependency that should be provided by its direct ancestor but isn't
#7906
Closed
zerocity opened this issue
Feb 14, 2020
· 1 comment
It is an CRA with only styled-components as dependencies see below for repo.
I am not sure is this an issue with the new yarn version or how styled-components is build/ describes its peer-deps.
Failed to compile.
./.yarn/$$virtual/styled-components-virtual-3b06c0951a/0/cache/styled-components-npm-5.0.1-87fcb612e6-2.zip/node_modules/styled-components/dist/styled-components.browser.esm.js
Module not found: A package is trying to access a peer dependency that should be provided by its direct ancestor but isn't
yarn dlx @yarnpkg/doctor
YN0000: ┌ Resolution step
➤ YN0000: └ Completed in 9.79s
➤ YN0000: ┌ Fetch step
➤ YN0000: └ Completed in 0.15s
➤ YN0000: ┌ Link step
➤ YN0000: └ Completed in 0.4s
➤ YN0000: Done in 10.35s
➤ YN0000: Found 1 package(s) to process
➤ YN0000: For a grand total of 5 file(s) to validate
➤ YN0000: ┌ /home/zerocity/projects/styled-components-yarn-2/package.json
➤ YN0000: │ /home/zerocity/projects/styled-components-yarn-2/package.json:8:36: Unmet transitive peer dependency on @testing-library/dom@>=5, via @testing-library/user-event@^7.1.2
➤ YN0000: │ /home/zerocity/projects/styled-components-yarn-2/package.json:12:26: Unmet transitive peer dependency on react-is@>= 16.8.0, via styled-components@^5.0.1
➤ YN0000: └ Completed in 0.74s
➤ YN0000: Failed with errors in 0.74s
Bug description
It is an CRA with only styled-components as dependencies see below for repo.
I am not sure is this an issue with the new yarn version or how styled-components is build/ describes its peer-deps.
What is the current behavior?
Failed to compile.
What is the expected behavior?
dont "crash"
Steps to Reproduce
Environment
2.0.0-rc.29
The text was updated successfully, but these errors were encountered: