File tree 10 files changed +38
-2
lines changed
10 files changed +38
-2
lines changed Original file line number Diff line number Diff line change @@ -415,6 +415,11 @@ where
415
415
416
416
srcmap ! ( node, true ) ;
417
417
418
+ if node. is_type_only {
419
+ keyword ! ( "type" ) ;
420
+ space ! ( ) ;
421
+ }
422
+
418
423
if let Some ( exported) = & node. exported {
419
424
emit ! ( node. orig) ;
420
425
space ! ( ) ;
@@ -470,7 +475,12 @@ where
470
475
471
476
keyword ! ( "export" ) ;
472
477
478
+ if node. type_only {
479
+ space ! ( ) ;
480
+ keyword ! ( "type" ) ;
481
+ }
473
482
formatting_space ! ( ) ;
483
+
474
484
if let Some ( spec) = namespace_spec {
475
485
emit ! ( spec) ;
476
486
if has_named_specs {
@@ -521,7 +531,15 @@ where
521
531
srcmap ! ( node, true ) ;
522
532
523
533
keyword ! ( "export" ) ;
524
- formatting_space ! ( ) ;
534
+
535
+ if node. type_only {
536
+ space ! ( ) ;
537
+ keyword ! ( "type" ) ;
538
+ space ! ( ) ;
539
+ } else {
540
+ formatting_space ! ( ) ;
541
+ }
542
+
525
543
punct ! ( "*" ) ;
526
544
formatting_space ! ( ) ;
527
545
keyword ! ( "from" ) ;
Original file line number Diff line number Diff line change
1
+ export type * as test from "./a.ts" ;
2
+ export type { a } from "./a.ts" ;
3
+ export { b , type b2 } from "./b.ts" ;
Original file line number Diff line number Diff line change
1
+ export type * as test from "./a.ts" ;
2
+ export type { a } from "./a.ts" ;
3
+ export { b , type b2 } from "./b.ts" ;
Original file line number Diff line number Diff line change
1
+ export type * as test from "./a.ts" ; export type { a } from "./a.ts" ; export { b , type b2 } from "./b.ts" ;
Original file line number Diff line number Diff line change
1
+ import type test from "./a.ts" ;
2
+ import type { a } from "./a.ts" ;
3
+ import type * as name from "./a.ts" ;
4
+ import { b , type c } from "./a.ts" ;
Original file line number Diff line number Diff line change
1
+ import type test from "./a.ts" ;
2
+ import type { a } from "./a.ts" ;
3
+ import type * as name from "./a.ts" ;
4
+ import { b , type c } from "./a.ts" ;
Original file line number Diff line number Diff line change
1
+ import type test from "./a.ts" ; import type { a } from "./a.ts" ; import type * as name from "./a.ts" ; import { b , type c } from "./a.ts" ;
Original file line number Diff line number Diff line change 1
1
import Test1 = MyNamespace . Test1 ;
2
2
import Test2 = Test1 ;
3
+ export import Test3 = Test1 ;
Original file line number Diff line number Diff line change 1
1
import Test1 = MyNamespace . Test1 ;
2
2
import Test2 = Test1 ;
3
+ export import Test3 = Test1 ;
Original file line number Diff line number Diff line change 1
- import Test1 = MyNamespace . Test1 ; import Test2 = Test1 ;
1
+ import Test1 = MyNamespace . Test1 ; import Test2 = Test1 ; export import Test3 = Test1 ;
You can’t perform that action at this time.
0 commit comments