Skip to content

Commit

Permalink
wip: testing compiler deprecation warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Apr 12, 2021
1 parent 24bab94 commit 422b13e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/compiler-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
],
"buildOptions": {
"name": "VueCompilerCore",
"compat": true,
"formats": [
"esm-bundler",
"cjs"
Expand Down
1 change: 1 addition & 0 deletions packages/compiler-dom/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"sideEffects": false,
"buildOptions": {
"name": "VueCompilerDOM",
"compat": true,
"formats": [
"esm-bundler",
"esm-browser",
Expand Down
4 changes: 4 additions & 0 deletions packages/compiler-dom/src/transforms/vOn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@ export const transformOn: DirectiveTransform = (dir, node, context) => {
const { modifiers } = dir
if (!modifiers.length) return baseResult

if (__COMPAT__ && __DEV__ && modifiers.includes('native')) {
console.warn('.native modifier for v-on has been removed')
}

let { key, value: handlerExp } = baseResult.props[0]
const {
keyModifiers,
Expand Down

0 comments on commit 422b13e

Please sign in to comment.