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

fix: add undeclared peer dependency webpack and @vue/compiler-sfc #1853

Merged
merged 1 commit into from
Jul 20, 2021

Conversation

merceyz
Copy link
Contributor

@merceyz merceyz commented Jul 16, 2021

What's the problem this PR addresses?

vue-loader@16 depends on webpack and @vue/compiler-sfc but doesn't declare it

Fixes #1844

How did you fix it?

Added webpack and @vue/compiler-sfc as peer dependencies

Copy link
Member

@haoqunjiang haoqunjiang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@haoqunjiang haoqunjiang merged commit 330d672 into vuejs:next Jul 20, 2021
@merceyz merceyz deleted the merceyz/fix/peer-dependencies branch July 20, 2021 07:57
@landerson-gc
Copy link

@sodatea This appears to be causing an unmet peer dep error for vue2 projects

npm ERR! peer dep missing: @vue/compiler-sfc@^3.0.8, required by [email protected]

relevant deps:

"vue": "^2.6.12",
"@vue/cli-service": "4.5.12",

@landerson-gc
Copy link

fix appears to be adding:

"vue-loader-v16": "npm:[email protected]",

to ones package.json

@Schweinepriester
Copy link

having the same issue as @landerson-gc with vue2 and can confirm the fix appears to be working, at least for installing. i went with downgrading "@vue/cli-service": "~4.5.13" to "@vue/cli-service": "~4.4.6" as an alternative fix. i'm hoping this will be fixed properly though.

@haoqunjiang
Copy link
Member

Fixed in v16.3.3

@chenyulun
Copy link

chenyulun commented Jul 26, 2024

packages/yarnpkg-extensions/sources/index.ts

[`vue-loader@<=16.3.3`, {
    peerDependencies: {
-    '@vue/compiler-sfc': `^3.0.8`,
+      '@vue/compiler-sfc': `^2.7.0 || ^3.0.8`,
      webpack: `^4.1.0 || ^5.0.0-0`,
    },
    peerDependenciesMeta: {
      '@vue/compiler-sfc': optionalPeerDep,
    },
  }]

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

Successfully merging this pull request may close these issues.

5 participants