Vigia

Memperbarui eslint-scope dari 8.x ke 9.x

Perbandingan API publik eslint-scope 8.4.0 dan 9.1.2, dihitung otomatis dari tipe TypeScript-nya. Tanda tangan yang berubah adalah kemungkinan perubahan tidak kompatibel, bukan kepastian.

Ringkasan

Jalur impor yang dihapus0
Ekspor yang dihapus0
Tanda tangan yang berubah1
Anggota kelas atau antarmuka yang dihapus4
Anggota kelas atau antarmuka yang berubah45
Baru ditandai usang48
Perubahan persyaratan (engines, dependensi peer)1
Ekspor baru13

Ekspor yang dihapus

Tidak ada yang terdeteksi.

Tanda tangan yang berubah

exportSebelumSesudah
eslint-scope · Definitionclass({ type: "CatchClause"; node: ESTree.CatchClause; parent: null; } | { type: "ClassName"; node: any; parent: null; } | { type: "FunctionName"; node: any; parent: null; } | { type: "ImplicitGlobalVariable"; node: any; parent: null; } | { type: "ImportBinding"; node: any; parent: ESTree.ImportDeclaration; } | { type: "Parameter"; node: any; parent: null; } | { type: "Variable"; node: ESTree.VariableDeclarator; parent: ESTree.VariableDeclaration; }) & { name: ESTree.Identifier; index: number | null; kind: string | null; }

Anggota kelas atau antarmuka yang dihapus

memberimportSebelum
Scope.impliciteslint-scope{ left: TReference[]; set: Map<string, Variable<Reference>>; variables: Variable<Reference>[]; }
BlockScope.impliciteslint-scope{ left: Reference[]; set: Map<string, Variable<Reference>>; variables: Variable<Reference>[]; }
ModuleScope.impliciteslint-scope{ left: Reference[]; set: Map<string, Variable<Reference>>; variables: Variable<Reference>[]; }
FunctionScope.impliciteslint-scope{ left: Reference[]; set: Map<string, Variable<Reference>>; variables: Variable<Reference>[]; }

Anggota kelas atau antarmuka yang berubah

memberSebelumSesudah
Scope.seteslint.Scope.ScopeMap<string, TVariable>
Scope.typeeslint.Scope.Scope"function" | "module" | "block" | "catch" | "class" | "class-field-initializer" | "class-static-block" | "for" | "function-expression-name" | "global" | "switch" | "with"
Scope.taintsMap<string, Variable<Reference>>Map<string, TVariable>
Scope.resolve(ref: Reference, noChain?: boolean | undefined): void(ident: ESTree.Identifier): TReference | null
Scope.througheslint.Scope.ScopeTReference[]
Scope.constructor<TVariable extends Variable = Variable<Reference>, TReference extends Reference = Reference>(scopeManager: ScopeManager, type: string, upper: Scope<Variable<Reference>, Reference> | null, block: ESTree.Node, isMethodDefinition: boolean): Scope<TVariable, TReference><TVariable extends Variable = Variable<Reference>, TReference extends Reference = Reference>(scopeManager: ScopeManager, type: "function" | "module" | "block" | "catch" | "class" | "class-field-initializer" | "class-static-block" | "for" | "function-expression-name" | "global" | "switch" | "with", u…
Scope.variableScopeScope<TVariable, TReference>Scope<Variable<Reference>, Reference>
Variable.defseslint.Scope.Definition[]Definition[]
Reference.initbooleanboolean | undefined
Reference.isReadeslint.Scope.Reference(): boolean
Reference.isWriteeslint.Scope.Reference(): boolean
Reference.partialbooleanboolean | undefined
Reference.identifierESTree.Identifierany
Reference.constructor(identifier: ESTree.Identifier, scope: Scope<Variable<Reference>, Reference>, flag: number, writeExpr: any, maybeImplicitGlobal: boolean, partial: boolean, init: boolean): Reference(ident: any, scope: Scope<Variable<Reference>, Reference>, flag: number, writeExpr: any, maybeImplicitGlobal: { pattern: ESTree.Pattern; node: ESTree.Node; } | null, partial: boolean, init: boolean): Reference
BlockScope.seteslint.Scope.ScopeMap<string, Variable<Reference>>
BlockScope.resolve(ref: Reference, noChain?: boolean | undefined): void(ident: ESTree.Identifier): Reference | null
BlockScope.througheslint.Scope.ScopeReference[]
BlockScope.constructor(scopeManager: ScopeManager, upper: Scope<Variable<Reference>, Reference>, block: ESTree.Node): BlockScope(scopeManager: ScopeManager, upperScope: Scope<Variable<Reference>, Reference>, block: ESTree.Node): BlockScope
BlockScope.variableScopeBlockScopeScope<Variable<Reference>, Reference>
BlockScope.isThisMaterialized(): boolean(): true
BlockScope.functionExpressionScopebooleanfalse
BlockScope.isArgumentsMaterialized(): boolean(): true
GlobalScope.seteslint.Scope.ScopeMap<string, Variable<Reference>>
GlobalScope.resolve(ref: Reference, noChain?: boolean | undefined): void(ident: ESTree.Identifier): Reference | null
GlobalScope.througheslint.Scope.ScopeReference[]
GlobalScope.variableScopeGlobalScopeScope<Variable<Reference>, Reference>
GlobalScope.isThisMaterialized(): boolean(): true
GlobalScope.functionExpressionScopebooleanfalse
GlobalScope.isArgumentsMaterialized(): boolean(): true
ModuleScope.seteslint.Scope.ScopeMap<string, Variable<Reference>>
ModuleScope.resolve(ref: Reference, noChain?: boolean | undefined): void(ident: ESTree.Identifier): Reference | null
ModuleScope.througheslint.Scope.ScopeReference[]
ModuleScope.constructor(scopeManager: ScopeManager, upper: Scope<Variable<Reference>, Reference>, block: ESTree.Node): ModuleScope(scopeManager: ScopeManager, upperScope: Scope<Variable<Reference>, Reference>, block: ESTree.Node): ModuleScope
ModuleScope.variableScopeModuleScopeScope<Variable<Reference>, Reference>
ModuleScope.isThisMaterialized(): boolean(): true
ModuleScope.functionExpressionScopebooleanfalse
ModuleScope.isArgumentsMaterialized(): boolean(): true
ScopeManager.globalScopeGlobalScopeGlobalScope | null
FunctionScope.seteslint.Scope.ScopeMap<string, Variable<Reference>>
FunctionScope.resolve(ref: Reference, noChain?: boolean | undefined): void(ident: ESTree.Identifier): Reference | null
FunctionScope.througheslint.Scope.ScopeReference[]
FunctionScope.constructor(scopeManager: ScopeManager, upper: Scope<Variable<Reference>, Reference>, block: ESTree.Node, isMethodDefinition: boolean): FunctionScope(scopeManager: ScopeManager, upperScope: Scope<Variable<Reference>, Reference>, block: ESTree.Node, isMethodDefinition: boolean): FunctionScope
FunctionScope.variableScopeFunctionScopeScope<Variable<Reference>, Reference>
FunctionScope.functionExpressionScopebooleanfalse
AnalyzeOptions.childVisitorKeysany{ readonly [type: string]: readonly string[]; } | null | undefined

Baru ditandai usang

export@deprecated
eslint-scope · Scope.taints—
eslint-scope · Scope.dynamic—
eslint-scope · Scope.resolve—
eslint-scope · Scope.isStatic—
eslint-scope · Scope.thisFound—
eslint-scope · Scope.isUsedName—
eslint-scope · Scope.isThisMaterialized—
eslint-scope · Scope.directCallToEvalScope—
eslint-scope · Scope.isArgumentsMaterialized—
eslint-scope · Variable.stack—
eslint-scope · Variable.tainted—
eslint-scope · Reference.partial—
eslint-scope · Reference.tainted—
eslint-scope · Reference.isStatic—
eslint-scope · BlockScope.taints—
eslint-scope · BlockScope.dynamic—
eslint-scope · BlockScope.resolve—
eslint-scope · BlockScope.isStatic—
eslint-scope · BlockScope.thisFound—
eslint-scope · BlockScope.isUsedName—
eslint-scope · BlockScope.directCallToEvalScope—
eslint-scope · GlobalScope.taints—
eslint-scope · GlobalScope.dynamic—
eslint-scope · GlobalScope.resolve—
eslint-scope · GlobalScope.isStatic—
eslint-scope · GlobalScope.thisFound—
eslint-scope · GlobalScope.isUsedName—
eslint-scope · GlobalScope.directCallToEvalScope—
eslint-scope · ModuleScope.taints—
eslint-scope · ModuleScope.dynamic—
eslint-scope · ModuleScope.resolve—
eslint-scope · ModuleScope.isStatic—
eslint-scope · ModuleScope.thisFound—
eslint-scope · ModuleScope.isUsedName—
eslint-scope · ModuleScope.directCallToEvalScope—
eslint-scope · ScopeManager.isModule—
eslint-scope · ScopeManager.acquireAll—
eslint-scope · ScopeManager.isImpliedStrict—
eslint-scope · ScopeManager.isStrictModeSupported—
eslint-scope · FunctionScope.taints—
eslint-scope · FunctionScope.dynamic—
eslint-scope · FunctionScope.resolve—
eslint-scope · FunctionScope.isStatic—
eslint-scope · FunctionScope.thisFound—
eslint-scope · FunctionScope.isUsedName—
eslint-scope · FunctionScope.isThisMaterialized—
eslint-scope · FunctionScope.directCallToEvalScope—
eslint-scope · FunctionScope.isArgumentsMaterialized—

Perubahan persyaratan (engines, dependensi peer)

SebelumSesudah
engines.node^18.18.0 || ^20.9.0 || >=21.1.0^20.19.0 || ^22.13.0 || >=24
Ekspor baru (13)
importexportkind
eslint-scopeversionvariable
eslint-scopeForScopeclass
eslint-scopeWithScopeclass
eslint-scopeCatchScopeclass
eslint-scopeClassScopeclass
eslint-scopeReferencerclass
eslint-scopeSwitchScopeclass
eslint-scopeJSXIdentifierinterface
eslint-scopePatternVisitorclass
eslint-scopeClassStaticBlockScopeclass
eslint-scopePatternVisitorCallbacktype
eslint-scopeClassFieldInitializerScopeclass
eslint-scopeFunctionExpressionNameScopeclass

Pertanyaan umum

Apa saja perubahan tidak kompatibel saat memperbarui eslint-scope dari 8 ke 9?

Antara eslint-scope 8.4.0 dan 9.1.2, Vigia menemukan 0 ekspor yang dihapus, 1 tanda tangan yang berubah, dan 49 anggota kelas atau antarmuka yang dihapus atau berubah.

Apa yang ditandai usang di eslint-scope 9?

48 ekspor atau anggota baru ditandai usang di eslint-scope 9.1.2.

Untuk agen

GET https://vigia.coredls.cloud/v1/packages/npm/eslint-scope/upgrade?from=8.4.0&to=9.1.2