Skip to content

Commit

Permalink
microsoft#17542 enabling case sensitivty by default
Browse files Browse the repository at this point in the history
This implements microsoft#17542 enable forceConsistentCasingInFileNames by default which fixes cross-platform compatability issues due to typescript not reporting different cases as an error in windows.
  • Loading branch information
Almenon authored Sep 30, 2018
1 parent e1a4c27 commit 1163de6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/compiler/program.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2049,7 +2049,11 @@ namespace ts {
const file = filesByName.get(path);
// try to check if we've already seen this file but with a different casing in path
// NOTE: this only makes sense for case-insensitive file systems, and only on files which are not redirected
if (file && options.forceConsistentCasingInFileNames) {

//default to true
let forceCasing = options.forceConsistentCasingInFileNames || options.forceConsistentCasingInFileNames==null

if (file && forceCasing) {
let inputName = fileName;
const checkedName = file.fileName;
const isRedirect = toPath(checkedName) !== toPath(inputName);
Expand Down

0 comments on commit 1163de6

Please sign in to comment.