Skip to content

fix(language-core): prevent the generation of generics in JS #4836

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 12 commits into from
Oct 24, 2024
Prev Previous commit
Next Next commit
Merge branch 'master' of https://github.com/vuejs/language-tools into…
… fix/issue-4826
  • Loading branch information
KazariEX committed Oct 23, 2024
commit 31bd7f4893fd7d7243b954cd51bed7cb9c6bf94b
12 changes: 6 additions & 6 deletions packages/language-core/lib/plugins/vue-tsx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ function createTsx(
: 'js';
});
const isTs = computed(() => {
return lang() !== 'js' && lang() !== 'jsx';
return lang.get() !== 'js' && lang.get() !== 'jsx';
});
const scriptRanges = computed(() =>
_sfc.script
Expand Down Expand Up @@ -185,11 +185,11 @@ function createTsx(
ts,
fileBaseName: path.basename(fileName),
sfc: _sfc,
lang: lang(),
isTs: isTs(),
scriptRanges: scriptRanges(),
scriptSetupRanges: scriptSetupRanges(),
templateCodegen: generatedTemplate(),
lang: lang.get(),
isTs: isTs.get(),
scriptRanges: scriptRanges.get(),
scriptSetupRanges: scriptSetupRanges.get(),
templateCodegen: generatedTemplate.get(),
compilerOptions: ctx.compilerOptions,
vueCompilerOptions: ctx.vueCompilerOptions,
edited: ctx.vueCompilerOptions.__test || (fileEditTimes.get(fileName) ?? 0) >= 2,
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.