@vue/compiler-sfc 3.3.3 → 3.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/compiler-sfc.cjs.js
CHANGED
|
@@ -18670,6 +18670,18 @@ function recordTypes(ctx, body, scope, asGlobal = false) {
|
|
|
18670
18670
|
stmt.source.value
|
|
18671
18671
|
);
|
|
18672
18672
|
Object.assign(scope.exportedTypes, sourceScope.exportedTypes);
|
|
18673
|
+
} else if (stmt.type === "ExportDefaultDeclaration" && stmt.declaration) {
|
|
18674
|
+
if (stmt.declaration.type !== "Identifier") {
|
|
18675
|
+
recordType(stmt.declaration, types, declares, "default");
|
|
18676
|
+
recordType(
|
|
18677
|
+
stmt.declaration,
|
|
18678
|
+
exportedTypes,
|
|
18679
|
+
exportedDeclares,
|
|
18680
|
+
"default"
|
|
18681
|
+
);
|
|
18682
|
+
} else if (types[stmt.declaration.name]) {
|
|
18683
|
+
exportedTypes["default"] = types[stmt.declaration.name];
|
|
18684
|
+
}
|
|
18673
18685
|
}
|
|
18674
18686
|
}
|
|
18675
18687
|
}
|
|
@@ -18683,12 +18695,12 @@ function recordTypes(ctx, body, scope, asGlobal = false) {
|
|
|
18683
18695
|
declares[key]._ownerScope = scope;
|
|
18684
18696
|
}
|
|
18685
18697
|
}
|
|
18686
|
-
function recordType(node, types, declares) {
|
|
18698
|
+
function recordType(node, types, declares, overwriteId) {
|
|
18687
18699
|
switch (node.type) {
|
|
18688
18700
|
case "TSInterfaceDeclaration":
|
|
18689
18701
|
case "TSEnumDeclaration":
|
|
18690
18702
|
case "TSModuleDeclaration": {
|
|
18691
|
-
const id = getId(node.id);
|
|
18703
|
+
const id = overwriteId || getId(node.id);
|
|
18692
18704
|
let existing = types[id];
|
|
18693
18705
|
if (existing) {
|
|
18694
18706
|
if (node.type === "TSModuleDeclaration") {
|
|
@@ -18718,7 +18730,7 @@ function recordType(node, types, declares) {
|
|
|
18718
18730
|
break;
|
|
18719
18731
|
}
|
|
18720
18732
|
case "ClassDeclaration":
|
|
18721
|
-
types[getId(node.id)] = node;
|
|
18733
|
+
types[overwriteId || getId(node.id)] = node;
|
|
18722
18734
|
break;
|
|
18723
18735
|
case "TSTypeAliasDeclaration":
|
|
18724
18736
|
types[node.id.name] = node.typeAnnotation;
|
|
@@ -20595,7 +20607,7 @@ function isStaticNode(node) {
|
|
|
20595
20607
|
return false;
|
|
20596
20608
|
}
|
|
20597
20609
|
|
|
20598
|
-
const version = "3.3.
|
|
20610
|
+
const version = "3.3.4";
|
|
20599
20611
|
const walk = estreeWalker.walk;
|
|
20600
20612
|
|
|
20601
20613
|
exports.babelParse = parser$2.parse;
|
|
@@ -48352,6 +48352,18 @@ function recordTypes(ctx, body, scope, asGlobal = false) {
|
|
|
48352
48352
|
stmt.source.value
|
|
48353
48353
|
);
|
|
48354
48354
|
Object.assign(scope.exportedTypes, sourceScope.exportedTypes);
|
|
48355
|
+
} else if (stmt.type === "ExportDefaultDeclaration" && stmt.declaration) {
|
|
48356
|
+
if (stmt.declaration.type !== "Identifier") {
|
|
48357
|
+
recordType(stmt.declaration, types, declares, "default");
|
|
48358
|
+
recordType(
|
|
48359
|
+
stmt.declaration,
|
|
48360
|
+
exportedTypes,
|
|
48361
|
+
exportedDeclares,
|
|
48362
|
+
"default"
|
|
48363
|
+
);
|
|
48364
|
+
} else if (types[stmt.declaration.name]) {
|
|
48365
|
+
exportedTypes["default"] = types[stmt.declaration.name];
|
|
48366
|
+
}
|
|
48355
48367
|
}
|
|
48356
48368
|
}
|
|
48357
48369
|
}
|
|
@@ -48365,12 +48377,12 @@ function recordTypes(ctx, body, scope, asGlobal = false) {
|
|
|
48365
48377
|
declares[key]._ownerScope = scope;
|
|
48366
48378
|
}
|
|
48367
48379
|
}
|
|
48368
|
-
function recordType(node, types, declares) {
|
|
48380
|
+
function recordType(node, types, declares, overwriteId) {
|
|
48369
48381
|
switch (node.type) {
|
|
48370
48382
|
case "TSInterfaceDeclaration":
|
|
48371
48383
|
case "TSEnumDeclaration":
|
|
48372
48384
|
case "TSModuleDeclaration": {
|
|
48373
|
-
const id = getId(node.id);
|
|
48385
|
+
const id = overwriteId || getId(node.id);
|
|
48374
48386
|
let existing = types[id];
|
|
48375
48387
|
if (existing) {
|
|
48376
48388
|
if (node.type === "TSModuleDeclaration") {
|
|
@@ -48400,7 +48412,7 @@ function recordType(node, types, declares) {
|
|
|
48400
48412
|
break;
|
|
48401
48413
|
}
|
|
48402
48414
|
case "ClassDeclaration":
|
|
48403
|
-
types[getId(node.id)] = node;
|
|
48415
|
+
types[overwriteId || getId(node.id)] = node;
|
|
48404
48416
|
break;
|
|
48405
48417
|
case "TSTypeAliasDeclaration":
|
|
48406
48418
|
types[node.id.name] = node.typeAnnotation;
|
|
@@ -50291,7 +50303,7 @@ function isStaticNode(node) {
|
|
|
50291
50303
|
return false;
|
|
50292
50304
|
}
|
|
50293
50305
|
|
|
50294
|
-
const version = "3.3.
|
|
50306
|
+
const version = "3.3.4";
|
|
50295
50307
|
const walk = walk$1;
|
|
50296
50308
|
|
|
50297
50309
|
export { MagicString, parse_1$1 as babelParse, compileScript, compileStyle, compileStyleAsync, compileTemplate, extractIdentifiers, generateCodeFrame, inferRuntimeType, invalidateTypeCache, isInDestructureAssignment, isStaticProperty, parse$7 as parse, parseCache, registerTS, resolveTypeElements, rewriteDefault, rewriteDefaultAST, shouldTransform as shouldTransformRef, transform as transformRef, transformAST as transformRefAST, version, walk, walkIdentifiers };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vue/compiler-sfc",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.4",
|
|
4
4
|
"description": "@vue/compiler-sfc",
|
|
5
5
|
"main": "dist/compiler-sfc.cjs.js",
|
|
6
6
|
"module": "dist/compiler-sfc.esm-browser.js",
|
|
@@ -33,11 +33,11 @@
|
|
|
33
33
|
"homepage": "https://github.com/vuejs/core/tree/main/packages/compiler-sfc#readme",
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@babel/parser": "^7.20.15",
|
|
36
|
-
"@vue/compiler-core": "3.3.
|
|
37
|
-
"@vue/compiler-dom": "3.3.
|
|
38
|
-
"@vue/compiler-ssr": "3.3.
|
|
39
|
-
"@vue/reactivity-transform": "3.3.
|
|
40
|
-
"@vue/shared": "3.3.
|
|
36
|
+
"@vue/compiler-core": "3.3.4",
|
|
37
|
+
"@vue/compiler-dom": "3.3.4",
|
|
38
|
+
"@vue/compiler-ssr": "3.3.4",
|
|
39
|
+
"@vue/reactivity-transform": "3.3.4",
|
|
40
|
+
"@vue/shared": "3.3.4",
|
|
41
41
|
"estree-walker": "^2.0.2",
|
|
42
42
|
"magic-string": "^0.30.0",
|
|
43
43
|
"postcss": "^8.1.10",
|