File tree 1 file changed +18
-6
lines changed
1 file changed +18
-6
lines changed Original file line number Diff line number Diff line change @@ -75,13 +75,25 @@ export async function compileFile(
75
75
return errors
76
76
}
77
77
78
- if (
79
- descriptor . styles . some ( ( s ) => s . lang ) ||
80
- ( descriptor . template && descriptor . template . lang )
81
- ) {
78
+ const styleLangs = descriptor . styles . map ( ( s ) => s . lang ) . filter ( Boolean )
79
+ const templateLang = descriptor . template ?. lang
80
+ if ( styleLangs . length && templateLang ) {
81
+ return [
82
+ `lang="${ styleLangs . join (
83
+ ',' ,
84
+ ) } " pre-processors for <style> and lang="${ templateLang } " ` +
85
+ `for <template> are currently not supported.` ,
86
+ ]
87
+ } else if ( styleLangs . length ) {
88
+ return [
89
+ `lang="${ styleLangs . join (
90
+ ',' ,
91
+ ) } " pre-processors for <style> are currently not supported.`,
92
+ ]
93
+ } else if ( templateLang ) {
82
94
return [
83
- `lang="x " pre-processors for <template> or <style> are currently not ` +
84
- `supported.` ,
95
+ `lang="${ templateLang } " pre-processors for ` +
96
+ `<template> are currently not supported.` ,
85
97
]
86
98
}
87
99
You can’t perform that action at this time.
0 commit comments