_id
stringlengths
21
254
text
stringlengths
1
93.7k
metadata
dict
TypeScript/tests/cases/conformance/es5/es5DateAPIs.ts_0_45
// @lib: es5 Date.UTC(2017); // should error
{ "end_byte": 45, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/es5/es5DateAPIs.ts" }
TypeScript/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.objectLiteralMethods.es5.ts_0_633
// @target: es5 // @lib: esnext // @filename: O1.ts const o1 = { async * f() { } } // @filename: O2.ts const o2 = { async * f() { const x = yield; } } // @filename: O3.ts const o3 = { async * f() { const x = yield 1; } } // @filename: O4.ts const o4 = { async * f() { ...
{ "end_byte": 633, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.objectLiteralMethods.es5.ts" }
TypeScript/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.functionExpressions.es5.ts_0_581
// @target: es5 // @lib: esnext // @filename: F1.ts const f1 = async function * () { } // @filename: F2.ts const f2 = async function * () { const x = yield; } // @filename: F3.ts const f3 = async function * () { const x = yield 1; } // @filename: F4.ts const f4 = async function * () { const x = yield* [1]; ...
{ "end_byte": 581, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.functionExpressions.es5.ts" }
TypeScript/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.functionDeclarations.es5.ts_0_518
// @target: es5 // @lib: esnext // @filename: F1.ts async function * f1() { } // @filename: F2.ts async function * f2() { const x = yield; } // @filename: F3.ts async function * f3() { const x = yield 1; } // @filename: F4.ts async function * f4() { const x = yield* [1]; } // @filename: F5.ts async function...
{ "end_byte": 518, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.functionDeclarations.es5.ts" }
TypeScript/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.classMethods.es5.ts_0_821
// @target: es5 // @lib: esnext // @filename: C1.ts class C1 { async * f() { } } // @filename: C2.ts class C2 { async * f() { const x = yield; } } // @filename: C3.ts class C3 { async * f() { const x = yield 1; } } // @filename: C4.ts class C4 { async * f() { const x ...
{ "end_byte": 821, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es5/asyncGenerators/emitter.asyncGenerators.classMethods.es5.ts" }
TypeScript/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.functionDeclarations.es2018.ts_0_521
// @target: es2018 // @lib: esnext // @filename: F1.ts async function * f1() { } // @filename: F2.ts async function * f2() { const x = yield; } // @filename: F3.ts async function * f3() { const x = yield 1; } // @filename: F4.ts async function * f4() { const x = yield* [1]; } // @filename: F5.ts async funct...
{ "end_byte": 521, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.functionDeclarations.es2018.ts" }
TypeScript/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.functionExpressions.es2018.ts_0_584
// @target: es2018 // @lib: esnext // @filename: F1.ts const f1 = async function * () { } // @filename: F2.ts const f2 = async function * () { const x = yield; } // @filename: F3.ts const f3 = async function * () { const x = yield 1; } // @filename: F4.ts const f4 = async function * () { const x = yield* [1...
{ "end_byte": 584, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.functionExpressions.es2018.ts" }
TypeScript/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.objectLiteralMethods.es2018.ts_0_636
// @target: es2018 // @lib: esnext // @filename: O1.ts const o1 = { async * f() { } } // @filename: O2.ts const o2 = { async * f() { const x = yield; } } // @filename: O3.ts const o3 = { async * f() { const x = yield 1; } } // @filename: O4.ts const o4 = { async * f() { ...
{ "end_byte": 636, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.objectLiteralMethods.es2018.ts" }
TypeScript/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.classMethods.es2018.ts_0_824
// @target: es2018 // @lib: esnext // @filename: C1.ts class C1 { async * f() { } } // @filename: C2.ts class C2 { async * f() { const x = yield; } } // @filename: C3.ts class C3 { async * f() { const x = yield 1; } } // @filename: C4.ts class C4 { async * f() { const...
{ "end_byte": 824, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2018/asyncGenerators/emitter.asyncGenerators.classMethods.es2018.ts" }
TypeScript/tests/cases/conformance/emitter/es2019/noCatchBinding/emitter.noCatchBinding.es2019.ts_0_145
// @target: es2019 function f() { try { } catch { } try { } catch { try { } catch { } } try { } catch { } finally { } }
{ "end_byte": 145, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2019/noCatchBinding/emitter.noCatchBinding.es2019.ts" }
TypeScript/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.classMethods.es2015.ts_0_824
// @target: es2015 // @lib: esnext // @filename: C1.ts class C1 { async * f() { } } // @filename: C2.ts class C2 { async * f() { const x = yield; } } // @filename: C3.ts class C3 { async * f() { const x = yield 1; } } // @filename: C4.ts class C4 { async * f() { const...
{ "end_byte": 824, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.classMethods.es2015.ts" }
TypeScript/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.functionDeclarations.es2015.ts_0_521
// @target: es2015 // @lib: esnext // @filename: F1.ts async function * f1() { } // @filename: F2.ts async function * f2() { const x = yield; } // @filename: F3.ts async function * f3() { const x = yield 1; } // @filename: F4.ts async function * f4() { const x = yield* [1]; } // @filename: F5.ts async funct...
{ "end_byte": 521, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.functionDeclarations.es2015.ts" }
TypeScript/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.objectLiteralMethods.es2015.ts_0_636
// @target: es2015 // @lib: esnext // @filename: O1.ts const o1 = { async * f() { } } // @filename: O2.ts const o2 = { async * f() { const x = yield; } } // @filename: O3.ts const o3 = { async * f() { const x = yield 1; } } // @filename: O4.ts const o4 = { async * f() { ...
{ "end_byte": 636, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.objectLiteralMethods.es2015.ts" }
TypeScript/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.functionExpressions.es2015.ts_0_584
// @target: es2015 // @lib: esnext // @filename: F1.ts const f1 = async function * () { } // @filename: F2.ts const f2 = async function * () { const x = yield; } // @filename: F3.ts const f3 = async function * () { const x = yield 1; } // @filename: F4.ts const f4 = async function * () { const x = yield* [1...
{ "end_byte": 584, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/emitter/es2015/asyncGenerators/emitter.asyncGenerators.functionExpressions.es2015.ts" }
TypeScript/tests/cases/conformance/override/override4.ts_0_443
// @declaration: true // @noImplicitOverride: true class B { p1: number = 1; p2: number = 1; p3: () => void; p4: () => void; foo (v: string) {} fooo (v: string) {} } class D extends B { p1: number = 2; override p2: number = 3; p3: () => void; override p4: () => void; overrid...
{ "end_byte": 443, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override4.ts" }
TypeScript/tests/cases/conformance/override/override_js4.ts_0_201
// @noImplicitOverride: true // @allowJs: true // @checkJs: true // @noEmit: true // @Filename: a.js class A { doSomething() {} } class B extends A { /** @override */ doSomethang() {} }
{ "end_byte": 201, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override_js4.ts" }
TypeScript/tests/cases/conformance/override/override1.ts_0_641
// @declaration: true // @noImplicitOverride: true class B { foo (v: string) {} fooo (v: string) {} } class D extends B { override foo (v: string) {} fooo (v: string) {} override bar(v: string) {} } class C { override foo(v: string) {} } function f () { return class extends B { ...
{ "end_byte": 641, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override1.ts" }
TypeScript/tests/cases/conformance/override/override_js1.ts_0_335
// @noImplicitOverride: true // @allowJs: true // @noEmit: true // @Filename: a.js class B { foo (v) {} fooo (v) {} } class D extends B { foo (v) {} /** @override */ fooo (v) {} /** @override */ bar(v) {} } class C { foo () {} /** @override */ fooo (v) {} /** @override */ ...
{ "end_byte": 335, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override_js1.ts" }
TypeScript/tests/cases/conformance/override/override5.ts_0_874
// @declaration: true // @noImplicitOverride: true class B { p1: number = 1; p2: number = 2; p3: number = 3; p4: number = 4; oop: number; pp: number; op: number; } class D extends B{ declare p1: number override declare p2: number; readonly override p3: number; override re...
{ "end_byte": 874, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override5.ts" }
TypeScript/tests/cases/conformance/override/override20.ts_0_408
// @target: esnext // @noImplicitOverride: true const Foo: C1 & C2 = class { m1() { } m2() { } } interface I1 { m1(): void; } interface I2 { m1(): void; m2(): void; } interface C1 { new(...args: any[]): I1; } interface C2 { new(...args: any[]): I2; } export class Bar ex...
{ "end_byte": 408, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override20.ts" }
TypeScript/tests/cases/conformance/override/override14.ts_0_139
// @noImplicitOverride: true // @target: esnext class Foo { property = 1 } class SubFoo extends Foo { declare property: number }
{ "end_byte": 139, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override14.ts" }
TypeScript/tests/cases/conformance/override/override10.ts_0_218
// @declaration: true // @noImplicitOverride: true abstract class Base { abstract foo(): unknown; abstract bar(): void; } abstract class Sub extends Base { abstract override foo(): number; bar() { } }
{ "end_byte": 218, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override10.ts" }
TypeScript/tests/cases/conformance/override/overrideKeywordOrder.ts_0_689
// @noTypesAndSymbols: true // @noEmit: true abstract class Base { static s1() {} static s2() {} abstract m1(): void; abstract m2(): void; p1: any; p2: any; } class Test1 extends Base { override async m1() {} async override m2() {} // error } class Test2 extends Base { override static s1() {} // err...
{ "end_byte": 689, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/overrideKeywordOrder.ts" }
TypeScript/tests/cases/conformance/override/override11.ts_0_127
class Base { foo = 1; } class Sub extends Base { constructor (override public foo: number) { super(); } }
{ "end_byte": 127, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override11.ts" }
TypeScript/tests/cases/conformance/override/override21.ts_0_131
// @target: esnext // @noImplicitOverride: true const foo = Symbol(); class A { } class B extends A { override [foo]() { } }
{ "end_byte": 131, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override21.ts" }
TypeScript/tests/cases/conformance/override/override15.ts_0_116
// @noImplicitOverride: true class A { doSomething() {} } class B extends A { override doSomethang() {} }
{ "end_byte": 116, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override15.ts" }
TypeScript/tests/cases/conformance/override/override12.ts_0_345
// @noImplicitOverride: true // @target: es2015,esnext class A { public m1(): number { return 0; } public m2(): number { return 0; } public m3(): void {} } class B extends A { override m1() { return 10; } override m2(): number { return 30; } ...
{ "end_byte": 345, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override12.ts" }
TypeScript/tests/cases/conformance/override/override8.ts_0_437
// @declaration: true // @noImplicitOverride: true class B { a: string } class D extends B { constructor(public a: string, public b: string) { super(); } } class BB { constructor(public a: string) { } } class DD extends BB { constructor(public a: string) { super(a) } } c...
{ "end_byte": 437, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override8.ts" }
TypeScript/tests/cases/conformance/override/overrideWithoutNoImplicitOverride1.ts_0_712
// @noImplicitOverride: false export declare class AmbientClass { override yadda(): void; } export class NonAmbientClass { override yadda(): void {} } ///// export declare class AmbientBase { foo(): void; } export declare class AmbientDerived extends AmbientBase { foo(): void; override bar(): ...
{ "end_byte": 712, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/overrideWithoutNoImplicitOverride1.ts" }
TypeScript/tests/cases/conformance/override/override16.ts_0_138
// @target: esnext,es2015 // @noImplicitOverride: true class A { foo?: string; } class B extends A { override foo = "string"; }
{ "end_byte": 138, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override16.ts" }
TypeScript/tests/cases/conformance/override/overrideParameterProperty.ts_0_476
// @noImplicitOverride: true class Base { p1!: string; } class C1 extends Base { constructor(public override p1: "hello") { super(); this.p1; } } class C2 extends Base { constructor(override p1: "hello") { super(); this.p1; } } class C3 extends Base { constructor(override public p1: "hel...
{ "end_byte": 476, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/overrideParameterProperty.ts" }
TypeScript/tests/cases/conformance/override/override17.ts_0_379
// @noImplicitOverride: true // @useDefineForClassFields: true // @target: es2015,esnext class A { public m1(): number { return 0; } public m2(): number { return 0; } public m3(): void {} } class B extends A { override m1() { return 10; } override m2(): numbe...
{ "end_byte": 379, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override17.ts" }
TypeScript/tests/cases/conformance/override/override13.ts_0_500
// @noImplicitOverride: true // @target: esnext class Foo { property = 1 static staticProperty = 2 } class SubFoo extends Foo { property = 42; staticProperty = 42; } class StaticSubFoo extends Foo { static property = 42; static staticProperty = 42; } class Intermediate extends Foo {} class ...
{ "end_byte": 500, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override13.ts" }
TypeScript/tests/cases/conformance/override/override9.ts_0_216
// @declaration: true // @noImplicitOverride: true interface B { foo (): void bar (): void } interface D extends B { foo (): void; override bar(): void; baz(): void; override bazz(): void; }
{ "end_byte": 216, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override9.ts" }
TypeScript/tests/cases/conformance/override/override18.ts_0_172
// @target: esnext,es2015 // @noImplicitOverride: true // @useDefineForClassFields: true class A { foo?: string; } class B extends A { override foo = "string"; }
{ "end_byte": 172, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override18.ts" }
TypeScript/tests/cases/conformance/override/override2.ts_0_541
// @declaration: true // @noImplicitOverride: true abstract class AB { abstract foo(v: string): void; abstract bar(v: string): void; abstract baz(v: string): void; } abstract class AD1 extends AB { } abstract class AD2 extends AB { abstract foo(v: ''): void // need override? } abstract class AD3 ex...
{ "end_byte": 541, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override2.ts" }
TypeScript/tests/cases/conformance/override/override_js2.ts_0_353
// @noImplicitOverride: true // @allowJs: true // @checkJs: true // @noEmit: true // @Filename: a.js class B { foo (v) {} fooo (v) {} } class D extends B { foo (v) {} /** @override */ fooo (v) {} /** @override */ bar(v) {} } class C { foo () {} /** @override */ fooo (v) {} ...
{ "end_byte": 353, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override_js2.ts" }
TypeScript/tests/cases/conformance/override/override6.ts_0_293
// @declaration: true // @noImplicitOverride: true class B { public baz: number = 1; constructor(public foo: string, public bar: number) { } } class D extends B { public bar: number = 1 constructor(public foo: string, public baz: number) { super(foo, 42) } }
{ "end_byte": 293, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override6.ts" }
TypeScript/tests/cases/conformance/override/override7.ts_0_835
// @declaration: true // @noImplicitOverride: false class B { p1: number = 1; p2: number = 2; p3: number = 3; p4: number = 4; } class D extends B{ declare p1: number override declare p2: number; readonly override p3: number; override readonly p4: number; static override sp: numb...
{ "end_byte": 835, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override7.ts" }
TypeScript/tests/cases/conformance/override/override19.ts_0_477
// @target: esnext // @noImplicitOverride: true type Foo = abstract new(...args: any) => any; declare function CreateMixin<C extends Foo, T extends Foo>(Context: C, Base: T): T & { new (...args: any[]): { context: InstanceType<C> } } class Context {} class A { doSomething() {} } class B extends CreateMixin(Co...
{ "end_byte": 477, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override19.ts" }
TypeScript/tests/cases/conformance/override/override3.ts_0_410
// @declaration: true // @noImplicitOverride: true declare class B { foo(): void bar(): void } declare class D extends B { foo (): void; override bar (): void; } class DB extends B { override foo(): void {} override bar(): void {} } class DD extends D { override foo(): void {} overrid...
{ "end_byte": 410, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override3.ts" }
TypeScript/tests/cases/conformance/override/override_js3.ts_0_229
// @noImplicitOverride: true // @allowJs: true // @checkJs: true // @noEmit: true // @Filename: a.js class B { foo (v) {} fooo (v) {} } class D extends B { override foo (v) {} /** @override */ fooo (v) {} }
{ "end_byte": 229, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/override/override_js3.ts" }
TypeScript/tests/cases/conformance/additionalChecks/noPropertyAccessFromIndexSignature1.ts_0_533
// @noPropertyAccessFromIndexSignature: true interface A { foo: string } interface B { [k: string]: string } interface C { foo: string [k: string]: string } declare const a: A; declare const b: B; declare const c: C; declare const d: C | undefined; // access property a.foo; a["foo"] // access inde...
{ "end_byte": 533, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/additionalChecks/noPropertyAccessFromIndexSignature1.ts" }
TypeScript/tests/cases/conformance/declarationEmit/libReferenceDeclarationEmit.ts_0_295
// @target: esnext // @module: commonjs // @lib: esnext // @declaration: true // @filename: file1.ts /// <reference lib="dom" preserve="true" /> export declare const elem: HTMLElement; // @filename: file2.ts /// <reference lib="dom" preserve="true" /> export {} declare const elem: HTMLElement;
{ "end_byte": 295, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/libReferenceDeclarationEmit.ts" }
TypeScript/tests/cases/conformance/declarationEmit/libReferenceNoLibBundle.ts_0_522
// @target: esnext // @module: amd // @noLib: true // @declaration: true // @outFile: bundle.js // Test that passing noLib disables <reference lib> resolution. // @filename: fakelib.ts interface Object { } interface Array<T> { } interface String { } interface Boolean { } interface Number { } interface Function { } in...
{ "end_byte": 522, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/libReferenceNoLibBundle.ts" }
TypeScript/tests/cases/conformance/declarationEmit/libReferenceNoLib.ts_0_503
// @target: esnext // @module: commonjs // @noLib: true // @declaration: true // Test that passing noLib disables <reference lib> resolution. // @filename: fakelib.ts interface Object { } interface Array<T> { } interface String { } interface Boolean { } interface Number { } interface Function { } interface RegExp { } ...
{ "end_byte": 503, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/libReferenceNoLib.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFile.ts_0_806
// @traceResolution: true // @target: esnext // @module: commonjs // @declaration: true // @filename: node_modules/ext/package.json { "name": "ext", "version": "1.0.0", "types": "index", "typesVersions": { ">=3.1.0-0": { "*" : ["ts3.1/*"] } } } // @filename: node_modules/ext/index.d.ts expo...
{ "end_byte": 806, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFile.ts" }
TypeScript/tests/cases/conformance/declarationEmit/exportDefaultExpressionComments.ts_0_69
// @declaration: true /** * JSDoc Comments */ export default null
{ "end_byte": 69, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/exportDefaultExpressionComments.ts" }
TypeScript/tests/cases/conformance/declarationEmit/classDoesNotDependOnPrivateMember.ts_0_102
//@declaration: true module M { interface I { } export class C { private x: I; } }
{ "end_byte": 102, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/classDoesNotDependOnPrivateMember.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.ambient.ts_0_888
// @traceResolution: true // @target: esnext // @module: commonjs // @declaration: true // @noImplicitReferences: true // @filename: node_modules/ext/package.json { "name": "ext", "version": "1.0.0", "types": "index", "typesVersions": { ">=3.1.0-0": { "*" : ["ts3.1/*"] } } } // @filename: n...
{ "end_byte": 888, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.ambient.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typeofImportTypeOnlyExport.ts_0_335
// @declaration: true // @Filename: button.ts import {classMap} from './lit.js'; export const c = classMap(); // @Filename: lit.ts class ClassMapDirective {} export type {ClassMapDirective}; export const directive = <C>(class_: C) => () => ({ directive: class_, }); export const classMap = directive(Class...
{ "end_byte": 335, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typeofImportTypeOnlyExport.ts" }
TypeScript/tests/cases/conformance/declarationEmit/leaveOptionalParameterAsWritten.ts_0_402
// @module: esnext // @outDir: dist // @declaration: true // @emitDeclarationOnly: true // @strictNullChecks: true // @Filename: a.ts export interface Foo {} // @Filename: b.ts import * as a from "./a"; declare global { namespace teams { export namespace calling { export import Foo = a.Foo; } } } /...
{ "end_byte": 402, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/leaveOptionalParameterAsWritten.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.ts_0_728
// @traceResolution: true // @target: esnext // @module: commonjs // @declaration: true // @filename: node_modules/ext/package.json { "name": "ext", "version": "1.0.0", "types": "index", "typesVersions": { ">=3.1.0-0": { "index" : ["ts3.1/index"] } } } // @filename: node...
{ "end_byte": 728, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFileBackReferenceToUnmapped.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.ts_0_759
// @traceResolution: true // @target: esnext // @module: commonjs // @declaration: true // @filename: node_modules/ext/package.json { "name": "ext", "version": "1.0.0", "types": "index", "typesVersions": { ">=3.1.0-0": { "*" : ["ts3.1/*"] } } } // @filename: node_modules/ext/index.d.ts expo...
{ "end_byte": 759, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typesVersionsDeclarationEmit.multiFileBackReferenceToSelf.ts" }
TypeScript/tests/cases/conformance/declarationEmit/declarationEmitWorkWithInlineComments.ts_0_863
// @declaration: true // @stripInternal:true export class Foo { constructor( /** @internal */ public isInternal1: string, /** @internal */ public isInternal2: string, /** @internal */ public isInternal3: string, // @internal public isInternal4: string, // nothing /** @internal */ ...
{ "end_byte": 863, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/declarationEmitWorkWithInlineComments.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typeReferenceRelatedFiles.ts_0_446
// @declaration: true // @filename: node_modules/@types/node/index.d.ts /// <reference path="fs.d.ts" /> // @filename: node_modules/@types/node/fs.d.ts declare module "fs" { interface FSWatcher {} } // @filename: node_modules/@types/node/package.json { "name": "@types/node", "version": "1.0.0" } // @filenam...
{ "end_byte": 446, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typeReferenceRelatedFiles.ts" }
TypeScript/tests/cases/conformance/declarationEmit/exportDefaultNamespace.ts_0_110
// @declaration: true export default function someFunc() { return 'hello!'; } someFunc.someProp = 'yo';
{ "end_byte": 110, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/exportDefaultNamespace.ts" }
TypeScript/tests/cases/conformance/declarationEmit/nullPropertyName.ts_0_1269
// @declaration: true function foo() {} // properties foo.x = 1; foo.y = 1; // keywords foo.break = 1; foo.case = 1; foo.catch = 1; foo.class = 1; foo.const = 1; foo.continue = 1; foo.debugger = 1; foo.default = 1; foo.delete = 1; foo.do = 1; foo.else = 1; foo.enum = 1; foo.export = 1; foo.extends = 1; foo.false = 1;...
{ "end_byte": 1269, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/nullPropertyName.ts" }
TypeScript/tests/cases/conformance/declarationEmit/libReferenceDeclarationEmitBundle.ts_0_313
// @target: esnext // @module: amd // @lib: esnext // @declaration: true // @outFile: bundle.js // @filename: file1.ts /// <reference lib="dom" preserve="true" /> export declare const elem: HTMLElement; // @filename: file2.ts /// <reference lib="dom" preserve="true" /> export {} declare const elem: HTMLElement;
{ "end_byte": 313, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/libReferenceDeclarationEmitBundle.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicates01.ts_0_153
// @declaration: true // @module: commonjs export class C { m(): this is D { return this instanceof D; } } export class D extends C { }
{ "end_byte": 153, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicates01.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitIdentifierPredicatesWithPrivateName01.ts_0_149
// @declaration: true // @module: commonjs interface I { a: number; } export function f(x: any): x is I { return typeof x.a === "number"; }
{ "end_byte": 149, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitIdentifierPredicatesWithPrivateName01.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicatesWithPrivateName01.ts_0_146
// @declaration: true // @module: commonjs export class C { m(): this is D { return this instanceof D; } } class D extends C { }
{ "end_byte": 146, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicatesWithPrivateName01.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicatesWithPrivateName02.ts_0_261
// @declaration: true // @module: commonjs interface Foo { a: string; b: number; c: boolean; } export const obj = { m(): this is Foo { let dis = this as {} as Foo; return dis.a != null && dis.b != null && dis.c != null; } }
{ "end_byte": 261, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicatesWithPrivateName02.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitIdentifierPredicates01.ts_0_120
// @declaration: true // @module: commonjs export function f(x: any): x is number { return typeof x === "number"; }
{ "end_byte": 120, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitIdentifierPredicates01.ts" }
TypeScript/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicates02.ts_0_268
// @declaration: true // @module: commonjs export interface Foo { a: string; b: number; c: boolean; } export const obj = { m(): this is Foo { let dis = this as {} as Foo; return dis.a != null && dis.b != null && dis.c != null; } }
{ "end_byte": 268, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/declarationEmit/typePredicates/declarationEmitThisPredicates02.ts" }
TypeScript/tests/cases/conformance/decorators/decoratorInAmbientContext.ts_0_217
// @target: esnext // @experimentalDecorators: true declare function decorator(target: any, key: any): any; const b = Symbol('b'); class Foo { @decorator declare a: number; @decorator declare [b]: number; }
{ "end_byte": 217, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/decoratorInAmbientContext.ts" }
TypeScript/tests/cases/conformance/decorators/missingDecoratorType.ts_0_352
// @target: ES5 // @experimentaldecorators: true // @noLib: true // @Filename: a.ts interface Object { } interface Array<T> { } interface String { } interface Boolean { } interface Number { } interface Function { } interface RegExp { } interface IArguments { } // @Filename: b.ts declare function dec(t, k, d); class ...
{ "end_byte": 352, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/missingDecoratorType.ts" }
TypeScript/tests/cases/conformance/decorators/legacyDecorators-contextualTypes.ts_0_611
// @target: esnext // @experimentalDecorators: true @((t) => { }) class C { constructor(@((t, k, i) => {}) p: any) {} @((t, k, d) => { }) static f() {} @((t, k, d) => { }) static get x() { return 1; } static set x(value) { } @((t, k, d) => { }) static accessor y = 1; @((t, k) =>...
{ "end_byte": 611, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/legacyDecorators-contextualTypes.ts" }
TypeScript/tests/cases/conformance/decorators/1.0lib-noErrors.ts_0_8260
// @target: ES5 /* ***************************************************************************** Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the Licens...
{ "end_byte": 8260, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/1.0lib-noErrors.ts" }
TypeScript/tests/cases/conformance/decorators/1.0lib-noErrors.ts_8261_17514
interface Function { /** * Calls the function, substituting the specified object for the this value of the function, and the specified array for the arguments of the function. * @param thisArg The object to be used as the this object. * @param argArray A set of arguments to be passed to the functi...
{ "end_byte": 17514, "start_byte": 8261, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/1.0lib-noErrors.ts" }
TypeScript/tests/cases/conformance/decorators/1.0lib-noErrors.ts_17516_23726
interface Number { /** * Returns a string representation of an object. * @param radix Specifies a radix for converting numeric values to strings. This value is only used for numbers. */ toString(radix?: number): string; /** * Returns a string representing a number in fixed-point no...
{ "end_byte": 23726, "start_byte": 17516, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/1.0lib-noErrors.ts" }
TypeScript/tests/cases/conformance/decorators/1.0lib-noErrors.ts_23727_31606
interface Date { /** Returns a string representation of a date. The format of the string depends on the locale. */ toString(): string; /** Returns a date as a string value. */ toDateString(): string; /** Returns a time as a string value. */ toTimeString(): string; /** Returns a value as a st...
{ "end_byte": 31606, "start_byte": 23727, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/1.0lib-noErrors.ts" }
TypeScript/tests/cases/conformance/decorators/1.0lib-noErrors.ts_31608_40003
declare var Date: { new (): Date; new (value: number): Date; new (value: string): Date; new (year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?: number, ms?: number): Date; (): string; prototype: Date; /** * Parses a string containing a date, and ret...
{ "end_byte": 40003, "start_byte": 31608, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/1.0lib-noErrors.ts" }
TypeScript/tests/cases/conformance/decorators/1.0lib-noErrors.ts_40004_48374
///////////////////////////// interface Array<T> { /** * Returns a string representation of an array. */ toString(): string; toLocaleString(): string; /** * Combines two or more arrays. * @param items Additional items to add to the end of array1. */ concat<U extends T[...
{ "end_byte": 48374, "start_byte": 40004, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/1.0lib-noErrors.ts" }
TypeScript/tests/cases/conformance/decorators/1.0lib-noErrors.ts_48379_49624
/** * Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function. * @param callbackfn A function that accepts up to four arguments....
{ "end_byte": 49624, "start_byte": 48379, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/1.0lib-noErrors.ts" }
TypeScript/tests/cases/conformance/decorators/decoratorMetadata-jsdoc.ts_0_238
// @experimentalDecorators: true // @emitDecoratorMetadata: true // @target: es5 // @module: commonjs declare var decorator: any; class X { @decorator() a?: string?; @decorator() b?: string!; @decorator() c?: *; }
{ "end_byte": 238, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/decoratorMetadata-jsdoc.ts" }
TypeScript/tests/cases/conformance/decorators/decoratorMetadataWithTypeOnlyImport2.ts_0_312
// @experimentalDecorators: true // @emitDecoratorMetadata: true // @filename: services.ts export namespace Services { export class Service {} } // @filename: index.ts import type { Services } from './services'; declare const decorator: any; export class Main { @decorator() field: Services.Service; }
{ "end_byte": 312, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/decoratorMetadataWithTypeOnlyImport2.ts" }
TypeScript/tests/cases/conformance/decorators/decoratorMetadata.ts_0_375
// @experimentalDecorators: true // @emitDecoratorMetadata: true // @target: es5 // @module: commonjs // @filename: service.ts export default class Service { } // @filename: component.ts import Service from "./service"; declare var decorator: any; @decorator class MyComponent { constructor(public Service: Service...
{ "end_byte": 375, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/decoratorMetadata.ts" }
TypeScript/tests/cases/conformance/decorators/decoratorCallGeneric.ts_0_167
// @experimentalDecorators: true interface I<T> { prototype: T, m: () => T } function dec<T>(c: I<T>) { } @dec class C { _brand: any; static m() {} }
{ "end_byte": 167, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/decoratorCallGeneric.ts" }
TypeScript/tests/cases/conformance/decorators/decoratorMetadataWithTypeOnlyImport.ts_0_376
// @experimentalDecorators: true // @emitDecoratorMetadata: true // @target: es5 // @module: commonjs // @filename: service.ts export class Service { } // @filename: component.ts import type { Service } from "./service"; declare var decorator: any; @decorator class MyComponent { constructor(public Service: Servic...
{ "end_byte": 376, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/decoratorMetadataWithTypeOnlyImport.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnTypeAlias.ts_0_61
declare function dec<T>(target: T): T; @dec type T = number;
{ "end_byte": 61, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnTypeAlias.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnImportEquals2.ts_0_222
// @module: commonjs // @Filename: decoratorOnImportEquals2_0.ts export var X; // @Filename: decoratorOnImportEquals2_1.ts @dec import lib = require('./decoratorOnImportEquals2_0'); declare function dec<T>(target: T): T;
{ "end_byte": 222, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnImportEquals2.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnVar.ts_0_59
declare function dec<T>(target: T): T; @dec var x: number;
{ "end_byte": 59, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnVar.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnFunctionExpression.ts_0_68
declare function dec<T>(target: T): T; var F = @dec function () { }
{ "end_byte": 68, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnFunctionExpression.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnInterface.ts_0_60
declare function dec<T>(target: T): T; @dec interface I { }
{ "end_byte": 60, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnInterface.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnInternalModule.ts_0_62
declare function dec<T>(target: T): T; @dec module M { }
{ "end_byte": 62, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnInternalModule.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnEnum2.ts_0_61
declare function dec<T>(target: T): T; enum E { @dec A }
{ "end_byte": 61, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnEnum2.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnArrowFunction.ts_0_62
declare function dec<T>(target: T): T; var F = @dec () => { }
{ "end_byte": 62, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnArrowFunction.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnFunctionDeclaration.ts_0_61
declare function dec<T>(target: T): T; @dec function F() { }
{ "end_byte": 61, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnFunctionDeclaration.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnEnum.ts_0_55
declare function dec<T>(target: T): T; @dec enum E { }
{ "end_byte": 55, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnEnum.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnImportEquals1.ts_0_124
declare function dec<T>(target: T): T; module M1 { export var X: number; } module M2 { @dec import X = M1.X; }
{ "end_byte": 124, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnImportEquals1.ts" }
TypeScript/tests/cases/conformance/decorators/invalid/decoratorOnFunctionParameter.ts_0_147
declare const dec: any; class C { n = true; } function direct(@dec this: C) { return this.n; } function called(@dec() this: C) { return this.n; }
{ "end_byte": 147, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/invalid/decoratorOnFunctionParameter.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratedBlockScopedClass1.ts_0_285
// @target: es5 // @experimentaldecorators: true // @emitDecoratorMetadata: true // @filename: a.ts function decorator() { return (target: new (...args: any[]) => any) => {} } @decorator() class Foo { public static func(): Foo { return new Foo(); } } Foo.func();
{ "end_byte": 285, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratedBlockScopedClass1.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratorInstantiateModulesInFunctionBodies.ts_0_381
// @target:es5 // @module:commonjs // @experimentaldecorators: true // @filename: a.ts // from #3108 export var test = 'abc'; // @filename: b.ts import { test } from './a'; function filter(handler: any) { return function (target: any, propertyKey: string) { // ... }; } class Wat { @filter(() => ...
{ "end_byte": 381, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratorInstantiateModulesInFunctionBodies.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratedClassExportsSystem1.ts_0_316
// @target: es6 // @experimentaldecorators: true // @emitDecoratorMetadata: true // @module: system // @filename: a.ts declare function forwardRef(x: any): any; declare var Something: any; @Something({ v: () => Testing123 }) export class Testing123 { static prop0: string; static prop1 = Testing123.prop0; }
{ "end_byte": 316, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratedClassExportsSystem1.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratorOnClass4.ts_0_112
// @target:es5 // @experimentaldecorators: true declare function dec(): <T>(target: T) => T; @dec() class C { }
{ "end_byte": 112, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratorOnClass4.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratedClassExportsCommonJS2.ts_0_255
// @target: es6 // @experimentaldecorators: true // @emitDecoratorMetadata: true // @module: commonjs // @filename: a.ts declare function forwardRef(x: any): any; declare var Something: any; @Something({ v: () => Testing123 }) export class Testing123 { }
{ "end_byte": 255, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratedClassExportsCommonJS2.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratorOnClass5.ts_0_112
// @target:es5 // @experimentaldecorators: true declare function dec(): <T>(target: T) => T; @dec() class C { }
{ "end_byte": 112, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratorOnClass5.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratorOnClass1.ts_0_104
// @target:es5 // @experimentaldecorators: true declare function dec<T>(target: T): T; @dec class C { }
{ "end_byte": 104, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratorOnClass1.ts" }
TypeScript/tests/cases/conformance/decorators/class/decoratedClassFromExternalModule.ts_0_221
// @target: es6 // @experimentaldecorators: true // @Filename: decorated.ts function decorate(target: any) { } @decorate export default class Decorated { } // @Filename: undecorated.ts import Decorated from 'decorated';
{ "end_byte": 221, "start_byte": 0, "url": "https://github.com/microsoft/TypeScript/blob/main/tests/cases/conformance/decorators/class/decoratedClassFromExternalModule.ts" }