@lit-labs/analyzer
Advanced tools
Comparing version 0.9.2 to 0.10.0-pre.0
@@ -30,3 +30,3 @@ /** | ||
get commandLine() { | ||
return (this._commandLine ?? (this._commandLine = getCommandLineFromProgram(this))); | ||
return (this._commandLine ??= getCommandLineFromProgram(this)); | ||
} | ||
@@ -33,0 +33,0 @@ getModule(modulePath) { |
@@ -139,3 +139,3 @@ /** | ||
get declarations() { | ||
return (this._declarations ?? (this._declarations = Array.from(this._declarationMap.keys()).map((name) => this.getDeclaration(name)))); | ||
return (this._declarations ??= Array.from(this._declarationMap.keys()).map((name) => this.getDeclaration(name))); | ||
} | ||
@@ -235,3 +235,3 @@ /** | ||
get heritage() { | ||
return (this._heritage ?? (this._heritage = this._getHeritage())); | ||
return (this._heritage ??= this._getHeritage()); | ||
} | ||
@@ -344,3 +344,3 @@ /** | ||
dereference(type) { | ||
const model = (this._model ?? (this._model = this._dereference())); | ||
const model = (this._model ??= this._dereference()); | ||
if (type !== undefined && model !== undefined && !(model instanceof type)) { | ||
@@ -360,3 +360,3 @@ throw new Error(`Expected reference to ${this.name} in module ${this.moduleSpecifier} to be of type ${type.name}`); | ||
get references() { | ||
return (this._references ?? (this._references = this._getReferences())); | ||
return (this._references ??= this._getReferences()); | ||
} | ||
@@ -363,0 +363,0 @@ } |
@@ -17,3 +17,2 @@ /** | ||
export const createPackageAnalyzer = (packagePath, options = {}) => { | ||
var _a; | ||
// This logic accepts either a path to folder containing a tsconfig.json | ||
@@ -30,3 +29,3 @@ // directly inside it or a path to a specific tsconfig file. If no tsconfig | ||
if (options.exclude !== undefined) { | ||
((_a = configFile.config).exclude ?? (_a.exclude = [])).push(...options.exclude); | ||
(configFile.config.exclude ??= []).push(...options.exclude); | ||
} | ||
@@ -40,4 +39,4 @@ commandLine = ts.parseJsonConfigFileContent(configFile.config /* json */, ts.sys /* host */, isDirectory ? packagePath : path.dirname(packagePath) /* basePath */, {} /* existingOptions */, configFileName /* configFileName */); | ||
// TODO(kschaaf): probably want to make this configurable | ||
module: 'ES2020', | ||
lib: ['es2020', 'DOM'], | ||
module: 'es2021', | ||
lib: ['es2021', 'DOM'], | ||
allowJs: true, | ||
@@ -44,0 +43,0 @@ skipLibCheck: true, |
{ | ||
"name": "@lit-labs/analyzer", | ||
"version": "0.9.2", | ||
"version": "0.10.0-pre.0", | ||
"publishConfig": { | ||
@@ -63,4 +63,4 @@ "access": "public" | ||
"package-json-type": "^1.0.3", | ||
"typescript": "~5.0.0" | ||
"typescript": "~5.2.0" | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
397683
4021
+ Addedtypescript@5.2.2(transitive)
- Removedtypescript@5.0.4(transitive)
Updatedtypescript@~5.2.0