mirror of
https://github.com/github/codeql.git
synced 2026-01-08 04:00:26 +01:00
JavaScript: Make default extractor options more sensible.
We now use module auto-detection and no TypeScript mode. This only affects extern extraction in `AutoBuild`, everything else sets these options explicitly. We currently do not have any ES2015 modules or TypeScript code in our externs, so in practice this is behaviour-preserving.
This commit is contained in:
@@ -162,7 +162,7 @@ public class ExtractorConfig {
|
||||
this.ecmaVersion = experimental ? ECMAVersion.ECMA2019 : ECMAVersion.ECMA2018;
|
||||
this.platform = Platform.AUTO;
|
||||
this.jsx = true;
|
||||
this.sourceType = SourceType.SCRIPT;
|
||||
this.sourceType = SourceType.AUTO;
|
||||
this.htmlHandling = HTMLHandling.ELEMENTS;
|
||||
this.tolerateParseErrors = true;
|
||||
if (experimental) {
|
||||
@@ -171,6 +171,7 @@ public class ExtractorConfig {
|
||||
this.esnext = true;
|
||||
this.v8Extensions = true;
|
||||
}
|
||||
this.typescriptMode = TypeScriptMode.NONE;
|
||||
this.defaultEncoding = StandardCharsets.UTF_8.name();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user