Skip to content

Commit

Permalink
fix: use toLowerCase, shouldn't involve locale here
Browse files Browse the repository at this point in the history
  • Loading branch information
sodatea committed Jul 28, 2021
1 parent 69d4aeb commit 8741ec8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vite/src/node/plugins/esbuild.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ export async function transformWithEsbuild(

// align with TypeScript 4.3
// https://github.com/microsoft/TypeScript/pull/42663
if (loadedCompilerOptions.target?.toLocaleLowerCase() === 'esnext') {
if (loadedCompilerOptions.target?.toLowerCase() === 'esnext') {
compilerOptionsForFile.useDefineForClassFields =
loadedCompilerOptions.useDefineForClassFields ?? true
}
Expand Down

0 comments on commit 8741ec8

Please sign in to comment.