chore(compiler-sfc): break in switch statement (#8347)

This commit is contained in:
丶远方 2023-05-19 07:46:39 +08:00 committed by GitHub
parent 4fa8da8576
commit 702711e771
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 5 deletions

View File

@ -225,13 +225,16 @@ function innerResolveTypeElements(
if (resolved) {
return resolveTypeElements(ctx, resolved, resolved._ownerScope)
}
break
}
case 'TSTypeQuery': {
const resolved = resolveTypeReference(ctx, node, scope)
if (resolved) {
return resolveTypeElements(ctx, resolved, resolved._ownerScope)
case 'TSTypeQuery':
{
const resolved = resolveTypeReference(ctx, node, scope)
if (resolved) {
return resolveTypeElements(ctx, resolved, resolved._ownerScope)
}
}
}
break
}
return ctx.error(`Unresolvable type: ${node.type}`, node, scope)
}