Skip to content

Commit

Permalink
fix: enable some syntax extensions by default for vue script compiler (
Browse files Browse the repository at this point in the history
  • Loading branch information
sodatea committed Sep 10, 2020
1 parent 34c09dc commit 9e5b16b
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 25 deletions.
5 changes: 4 additions & 1 deletion packages/@vue/cli-service/lib/config/base.js
Expand Up @@ -133,7 +133,10 @@ module.exports = (api, options) => {
.end()
.use('vue-loader')
.loader(require.resolve('vue-loader-v16'))
.options(vueLoaderCacheConfig)
.options({
...vueLoaderCacheConfig,
babelParserPlugins: ['jsx', 'classProperties', 'decorators-legacy']
})
.end()
.end()

Expand Down
2 changes: 1 addition & 1 deletion packages/@vue/cli-service/package.json
Expand Up @@ -80,7 +80,7 @@
"webpack-merge": "^4.2.2"
},
"optionalDependencies": {
"vue-loader-v16": "npm:vue-loader@^16.0.0-beta.3"
"vue-loader-v16": "npm:vue-loader@^16.0.0-beta.7"
},
"peerDependencies": {
"@vue/compiler-sfc": "^3.0.0-beta.14",
Expand Down
51 changes: 28 additions & 23 deletions yarn.lock
Expand Up @@ -9,25 +9,6 @@
dependencies:
fswin "^2.17.1227"

"@ant-design-vue/babel-helper-vue-transform-on@^1.0.0":
version "1.0.1"
resolved "https://registry.yarnpkg.com/@ant-design-vue/babel-helper-vue-transform-on/-/babel-helper-vue-transform-on-1.0.1.tgz#d219d92f4e1fc5e7add211c347c7fa000518b623"
integrity sha512-dOAPf/tCM2lCG8FhvOMFBaOdMElMEGhOoocMXEWvHW2l1KIex+UibDcq4bdBEJpDMLrnbNOqci9E7P2dARP6lg==

"@ant-design-vue/babel-plugin-jsx@^1.0.0-0":
version "1.0.0-rc.1"
resolved "https://registry.yarnpkg.com/@ant-design-vue/babel-plugin-jsx/-/babel-plugin-jsx-1.0.0-rc.1.tgz#ae56cecbda9f08691bcf92dfe98e2416e77d758b"
integrity sha512-x7PfAHSs5/emIuey1Df7Bh/vJU27S9KBdufzoAA7kgwTpEpY85R7CXD9gl6sJFB7aG2pZpl4Tmm+FsHlzgp7fA==
dependencies:
"@ant-design-vue/babel-helper-vue-transform-on" "^1.0.0"
"@babel/helper-module-imports" "^7.0.0"
"@babel/plugin-syntax-jsx" "^7.0.0"
"@babel/traverse" "^7.0.0"
"@babel/types" "^7.0.0"
camelcase "^6.0.0"
html-tags "^3.1.0"
svg-tags "^1.0.0"

"@apollo/federation@0.17.0":
version "0.17.0"
resolved "https://registry.yarnpkg.com/@apollo/federation/-/federation-0.17.0.tgz#549c3f8c8d5a33db28a4c628d8a9fb5430758c62"
Expand Down Expand Up @@ -2986,6 +2967,11 @@
resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-5.2.7.tgz#315d570ccb56c53452ff8638738df60726d5b6ea"
integrity sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==

"@types/mocha@^8.0.1":
version "8.0.3"
resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-8.0.3.tgz#51b21b6acb6d1b923bbdc7725c38f9f455166402"
integrity sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==

"@types/node-fetch@2.5.7":
version "2.5.7"
resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.5.7.tgz#20a2afffa882ab04d44ca786449a276f9f6bbf3c"
Expand Down Expand Up @@ -3225,6 +3211,25 @@
resolved "https://registry.yarnpkg.com/@vue/babel-helper-vue-jsx-merge-props/-/babel-helper-vue-jsx-merge-props-1.0.0.tgz#048fe579958da408fb7a8b2a3ec050b50a661040"
integrity sha512-6tyf5Cqm4m6v7buITuwS+jHzPlIPxbFzEhXR5JGZpbrvOcp1hiQKckd305/3C7C36wFekNTQSxAtgeM0j0yoUw==

"@vue/babel-helper-vue-transform-on@^1.0.0-rc.2":
version "1.0.0-rc.2"
resolved "https://registry.yarnpkg.com/@vue/babel-helper-vue-transform-on/-/babel-helper-vue-transform-on-1.0.0-rc.2.tgz#7246341f666e7c6e65b13da420e2ce85714fbbca"
integrity sha512-1+7CwjQ0Kasml6rHoNQUmbISwqLNNfFVBUcZl6QBremUl296ZmLrVQPqJP5pyAAWjZke5bpI1hlj+LVVuT7Jcg==

"@vue/babel-plugin-jsx@^1.0.0-0":
version "1.0.0-rc.2"
resolved "https://registry.yarnpkg.com/@vue/babel-plugin-jsx/-/babel-plugin-jsx-1.0.0-rc.2.tgz#2c72a6bf6d10f57bb6bf1a2799214a541933345b"
integrity sha512-NVTDsaYShZx8ZqZo1Z0ndNrdoLfwRTwz0e6S+7SEn3j21WwlbVHMhD6t/tDBhvscwAQ5N/AFuCCrf90iyC5sHA==
dependencies:
"@babel/helper-module-imports" "^7.0.0"
"@babel/plugin-syntax-jsx" "^7.0.0"
"@babel/traverse" "^7.0.0"
"@babel/types" "^7.0.0"
"@vue/babel-helper-vue-transform-on" "^1.0.0-rc.2"
camelcase "^6.0.0"
html-tags "^3.1.0"
svg-tags "^1.0.0"

"@vue/babel-plugin-transform-vue-jsx@^1.1.2":
version "1.1.2"
resolved "https://registry.yarnpkg.com/@vue/babel-plugin-transform-vue-jsx/-/babel-plugin-transform-vue-jsx-1.1.2.tgz#c0a3e6efc022e75e4247b448a8fc6b86f03e91c0"
Expand Down Expand Up @@ -19978,10 +19983,10 @@ vue-jest@^3.0.5:
tsconfig "^7.0.0"
vue-template-es2015-compiler "^1.6.0"

"vue-loader-v16@npm:vue-loader@^16.0.0-beta.3":
version "16.0.0-beta.4"
resolved "https://registry.yarnpkg.com/vue-loader/-/vue-loader-16.0.0-beta.4.tgz#1d9d7894f430992096727c4414bcf3b1ae8c1be9"
integrity sha512-uh/+SIwoN+hny0+GqxdkTuEmt1NV4wb8etF5cKkB1YVMv29ck0byrmkt8IIYadQ3r/fiYsr2brGJqP+hytQwuw==
"vue-loader-v16@npm:vue-loader@^16.0.0-beta.7":
version "16.0.0-beta.7"
resolved "https://registry.yarnpkg.com/vue-loader/-/vue-loader-16.0.0-beta.7.tgz#6f2726fa0e2b1fbae67895c47593bbf69f2b9ab8"
integrity sha512-xQ8/GZmRPdQ3EinnE0IXwdVoDzh7Dowo0MowoyBuScEBXrRabw6At5/IdtD3waKklKW5PGokPsm8KRN6rvQ1cw==
dependencies:
"@types/mini-css-extract-plugin" "^0.9.1"
chalk "^3.0.0"
Expand Down

0 comments on commit 9e5b16b

Please sign in to comment.