Skip to content

Commit fcf27e3

Browse files
committed
fixup! fix: compatibility with Vue 2.7
1 parent a648958 commit fcf27e3

File tree

1 file changed

+6
-4
lines changed
  • packages/@vue/cli-service/lib/config

1 file changed

+6
-4
lines changed

packages/@vue/cli-service/lib/config/base.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,17 +61,19 @@ module.exports = (api, options) => {
6161

6262
if (vueMajor === 2) {
6363
// for Vue 2 projects
64-
const vueLoaderCacheConfig = api.genCacheConfig('vue-loader', {
64+
const partialIdentifier = {
6565
'vue-loader': require('@vue/vue-loader-v15/package.json').version,
66-
'@vue/component-compiler-utils': require('@vue/component-compiler-utils/package.json').version,
67-
})
66+
'@vue/component-compiler-utils': require('@vue/component-compiler-utils/package.json').version
67+
}
6868

6969
try {
70-
vueLoaderCacheConfig['vue-template-compiler'] = require('vue-template-compiler/package.json').version
70+
partialIdentifier['vue-template-compiler'] = require('vue-template-compiler/package.json').version
7171
} catch (e) {
7272
// For Vue 2.7 projects, `vue-template-compiler` is not required
7373
}
7474

75+
const vueLoaderCacheConfig = api.genCacheConfig('vue-loader', partialIdentifier)
76+
7577
webpackConfig.resolve
7678
.alias
7779
.set(

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy