chore: bump deps

This commit is contained in:
Evan You
2021-08-22 15:33:21 -04:00
parent 73f8cae465
commit 84b24a71f0
7 changed files with 804 additions and 1159 deletions

View File

@@ -31,15 +31,15 @@
},
"homepage": "https://github.com/vuejs/vue-next/tree/master/packages/compiler-sfc#readme",
"dependencies": {
"@babel/parser": "^7.13.9",
"@babel/types": "^7.13.0",
"@babel/parser": "^7.15.0",
"@babel/types": "^7.15.0",
"@types/estree": "^0.0.48",
"@vue/compiler-core": "3.2.4",
"@vue/compiler-dom": "3.2.4",
"@vue/compiler-ssr": "3.2.4",
"@vue/shared": "3.2.4",
"consolidate": "^0.16.0",
"estree-walker": "^2.0.1",
"estree-walker": "^2.0.2",
"hash-sum": "^2.0.0",
"lru-cache": "^5.1.1",
"magic-string": "^0.25.7",

View File

@@ -1752,10 +1752,15 @@ function extractEventNames(
) {
const typeNode = eventName.typeAnnotation.typeAnnotation
if (typeNode.type === 'TSLiteralType') {
emits.add(String(typeNode.literal.value))
if (typeNode.literal.type !== 'UnaryExpression') {
emits.add(String(typeNode.literal.value))
}
} else if (typeNode.type === 'TSUnionType') {
for (const t of typeNode.types) {
if (t.type === 'TSLiteralType') {
if (
t.type === 'TSLiteralType' &&
t.literal.type !== 'UnaryExpression'
) {
emits.add(String(t.literal.value))
}
}