Skip to content

The TSImportEqualsDeclaration is typing is not remove. #8230

@underfin

Description

@underfin

Input

import { X } from "abc";
// assume Y is a type only namespace
import Z = X.Y.Z;

function a(t: Z.T) {
  console.log(t);
}

Output

import { X } from "abc";
var Z = X.Y.Z;
function a(t) {
	console.log(t);
}

Expected

The Z is a typing, it should be removed.

function a(t) {
  console.log(t);
}

The bable also have a issue babel/babel#15942, and also have a pr to resolve it babel/babel#17025.

related rolldown/rolldown#3287

Metadata

Metadata

Assignees

Labels

C-bugCategory - Bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions