File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed
extensions/vscode-vue-language-features/schemas
packages/vue-typescript/src Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 1717 "markdownDescription" : " https://github.com/johnsoncodehk/volar/pull/351"
1818 },
1919 "experimentalImplicitWrapComponentOptionsWithDefineComponent" : {
20- "type" : " boolean" ,
20+ "enum" : [
21+ true ,
22+ false ,
23+ " onlyJs"
24+ ],
2125 "markdownDescription" : " Implicit wrap object literal component options export with `defineComponent()`."
2226 },
2327 "experimentalTemplateCompilerOptions" : {
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ export interface ITemplateScriptData {
1212
1313export interface VueCompilerOptions {
1414 experimentalCompatMode ?: 2 | 3 ;
15- experimentalImplicitWrapComponentOptionsWithDefineComponent ?: boolean ;
15+ experimentalImplicitWrapComponentOptionsWithDefineComponent ?: boolean | 'onlyJs' ;
1616 experimentalTemplateCompilerOptions ?: any ;
1717 experimentalTemplateCompilerOptionsRequirePath ?: string ;
1818 experimentalDisableTemplateSupport ?: boolean ;
Original file line number Diff line number Diff line change @@ -46,7 +46,9 @@ export function useSfcScriptGen<T extends 'template' | 'script'>(
4646 return bindTexts ;
4747 } ,
4848 getVueLibraryName ( compilerOptions . experimentalCompatMode === 2 ) ,
49- ! ! compilerOptions . experimentalImplicitWrapComponentOptionsWithDefineComponent ,
49+ ( compilerOptions . experimentalImplicitWrapComponentOptionsWithDefineComponent ?? 'onlyJs' ) === 'onlyJs'
50+ ? lang . value === 'js' || lang . value === 'jsx'
51+ : ! ! compilerOptions . experimentalImplicitWrapComponentOptionsWithDefineComponent ,
5052 )
5153 ) ;
5254 const file = computed ( ( ) => {
You can’t perform that action at this time.
0 commit comments