From bcfe279fba865763c87f9cd8d5a2d0b2cbf451be Mon Sep 17 00:00:00 2001 From: David Sherret Date: Fri, 21 Oct 2022 11:20:18 -0400 Subject: feat(unstable/npm): initial type checking of npm specifiers (#16332) --- .../npm/registry/@denotest/cjs-default-export/1.0.0/index.d.ts | 6 ++++++ .../npm/registry/@denotest/cjs-default-export/1.0.0/package.json | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/index.d.ts (limited to 'cli/tests/testdata/npm/registry/@denotest/cjs-default-export') diff --git a/cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/index.d.ts b/cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/index.d.ts new file mode 100644 index 000000000..90fdfe5f6 --- /dev/null +++ b/cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/index.d.ts @@ -0,0 +1,6 @@ +export default function (): number; +export declare function named(): number; +declare class MyClass { + static someStaticMethod(): string; +} +export { MyClass }; diff --git a/cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/package.json b/cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/package.json index 4765d25d2..8da28b919 100644 --- a/cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/package.json +++ b/cli/tests/testdata/npm/registry/@denotest/cjs-default-export/1.0.0/package.json @@ -1,4 +1,5 @@ { "name": "@denotest/cjs-default-export", - "version": "1.0.0" + "version": "1.0.0", + "types": "./index.d.ts" } -- cgit v1.2.3