/
nodeModulesImportModeDeclarationEmit1(module=node16).errors.txt
37 lines (31 loc) · 1.98 KB
/
nodeModulesImportModeDeclarationEmit1(module=node16).errors.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
/index.ts(6,50): error TS2821: Import assertions are only supported when the '--module' option is set to 'esnext' or 'nodenext'.
/index.ts(7,14): error TS2305: Module '"pkg"' has no exported member 'ImportInterface'.
/index.ts(7,49): error TS2821: Import assertions are only supported when the '--module' option is set to 'esnext' or 'nodenext'.
==== /index.ts (3 errors) ====
import type { RequireInterface } from "pkg" assert { "resolution-mode": "require" };
import type { ImportInterface } from "pkg" assert { "resolution-mode": "import" };
export interface LocalInterface extends RequireInterface, ImportInterface {}
import {type RequireInterface as Req} from "pkg" assert { "resolution-mode": "require" };
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
!!! error TS2821: Import assertions are only supported when the '--module' option is set to 'esnext' or 'nodenext'.
import {type ImportInterface as Imp} from "pkg" assert { "resolution-mode": "import" };
~~~~~~~~~~~~~~~
!!! error TS2305: Module '"pkg"' has no exported member 'ImportInterface'.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
!!! error TS2821: Import assertions are only supported when the '--module' option is set to 'esnext' or 'nodenext'.
export interface Loc extends Req, Imp {}
export type { RequireInterface } from "pkg" assert { "resolution-mode": "require" };
export type { ImportInterface } from "pkg" assert { "resolution-mode": "import" };
==== /node_modules/pkg/package.json (0 errors) ====
{
"name": "pkg",
"version": "0.0.1",
"exports": {
"import": "./import.js",
"require": "./require.js"
}
}
==== /node_modules/pkg/import.d.ts (0 errors) ====
export interface ImportInterface {}
==== /node_modules/pkg/require.d.ts (0 errors) ====
export interface RequireInterface {}