mirror of
https://github.com/denoland/deno.git
synced 2025-08-04 19:08:15 +00:00
fix(check): regression where config "types" entries caused type checking errors (#18124)
Closes #18117 Closes #18121 (this is just over 10ms faster in a directory one up from the root folder) cc @nayeemrmn
This commit is contained in:
parent
e4430400ce
commit
8db853514c
18 changed files with 170 additions and 174 deletions
|
@ -185,10 +185,16 @@ fn parse_compiler_options(
|
|||
|
||||
for (key, value) in compiler_options.iter() {
|
||||
let key = key.as_str();
|
||||
if IGNORED_COMPILER_OPTIONS.contains(&key) {
|
||||
items.push(key.to_string());
|
||||
} else {
|
||||
filtered.insert(key.to_string(), value.to_owned());
|
||||
// We don't pass "types" entries to typescript via the compiler
|
||||
// options and instead provide those to tsc as "roots". This is
|
||||
// because our "types" behavior is at odds with how TypeScript's
|
||||
// "types" works.
|
||||
if key != "types" {
|
||||
if IGNORED_COMPILER_OPTIONS.contains(&key) {
|
||||
items.push(key.to_string());
|
||||
} else {
|
||||
filtered.insert(key.to_string(), value.to_owned());
|
||||
}
|
||||
}
|
||||
}
|
||||
let value = serde_json::to_value(filtered)?;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue