Skip to content

Commit 0cbdf5f

Browse files
committed
fix: specify vue version in the web component demo html
1 parent 45ef65e commit 0cbdf5f

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

packages/@vue/cli-service/lib/commands/build/demo-wc.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<!DOCTYPE html>
22
<meta charset="utf-8">
33
<title><%- htmlWebpackPlugin.options.libName %> demo</title>
4-
<script src="https://unpkg.com/vue"></script>
4+
<script src="https://unpkg.com/vue@<%- htmlWebpackPlugin.options.vueMajor %>"></script>
55
<script src="./<%- htmlWebpackPlugin.options.libName %>.js"></script>
66

77
<% for (const comp of htmlWebpackPlugin.options.components) { %>

packages/@vue/cli-service/lib/commands/build/resolveWcConfig.js

+1
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ module.exports = (api, { target, entry, name, 'inline-vue': inlineVue }) => {
8989
inject: false,
9090
filename: 'demo.html',
9191
libName,
92+
vueMajor,
9293
components:
9394
prefix === ''
9495
? [libName]

0 commit comments

Comments
 (0)