File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
packages/compiler-sfc/src Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,7 @@ export interface SFCScriptBlock extends SFCBlock {
47
47
imports ?: Record < string , ImportBinding >
48
48
scriptAst ?: import ( '@babel/types' ) . Statement [ ]
49
49
scriptSetupAst ?: import ( '@babel/types' ) . Statement [ ]
50
+ src : string
50
51
}
51
52
52
53
export interface SFCStyleBlock extends SFCBlock {
@@ -97,7 +98,7 @@ export function parse(
97
98
pad = false ,
98
99
ignoreEmpty = true ,
99
100
compiler = CompilerDOM ,
100
- defaultScriptLang
101
+ defaultScriptLang = 'js'
101
102
} : SFCParseOptions = { }
102
103
) : SFCParseResult {
103
104
const sourceKey =
@@ -107,7 +108,7 @@ export function parse(
107
108
sourceRoot +
108
109
pad +
109
110
compiler . parse +
110
- ( defaultScriptLang != null ? '@' + defaultScriptLang : '' )
111
+ defaultScriptLang
111
112
const cache = sourceToSFC . get ( sourceKey )
112
113
if ( cache ) {
113
114
return cache
You can’t perform that action at this time.
0 commit comments