mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
33 lines
1.3 KiB
Plaintext
33 lines
1.3 KiB
Plaintext
b.ts(2,12): error TS1380: An import alias cannot reference a declaration that was imported using 'import type'.
|
|
b.ts(3,13): error TS1380: An import alias cannot reference a declaration that was imported using 'import type'.
|
|
c.ts(2,12): error TS1380: An import alias cannot reference a declaration that was imported using 'import type'.
|
|
|
|
|
|
==== a.ts (0 errors) ====
|
|
export class A {}
|
|
|
|
==== b.ts (2 errors) ====
|
|
import type * as a from './a';
|
|
import A = a.A; // Error
|
|
~~~
|
|
!!! error TS1380: An import alias cannot reference a declaration that was imported using 'import type'.
|
|
!!! related TS1376 b.ts:1:18: 'a' was imported here.
|
|
import aa = a; // Error
|
|
~
|
|
!!! error TS1380: An import alias cannot reference a declaration that was imported using 'import type'.
|
|
!!! related TS1376 b.ts:1:18: 'a' was imported here.
|
|
|
|
const x = 0;
|
|
export { a, A, x };
|
|
|
|
==== c.ts (1 errors) ====
|
|
import * as b from './b';
|
|
import A = b.a.A; // Error
|
|
~~~~~
|
|
!!! error TS1380: An import alias cannot reference a declaration that was imported using 'import type'.
|
|
!!! related TS1376 b.ts:1:18: 'a' was imported here.
|
|
import AA = b.A; // Error
|
|
|
|
import x = b.x;
|
|
console.log(x);
|
|
|