Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TypeScript] FormData can only imported when esModuleInterop flag is set. #470

Open
nonoyona opened this issue May 31, 2020 · 1 comment

Comments

@nonoyona
Copy link

I actually don't know exactly what this means, but wouldn't it be possible to implement the index.d.ts file so that FormData can be imported without setting the flag?
Currently, it is exported like this:

export = FormData;
...
declare class FormData extends stream.Readable { ...

Is there any reason why we could not change it to:

export default class FormData extends stream.Readable { ...

Best regards
Noah

@nonoyona nonoyona changed the title FormData can only imported when esModuleInterop flag is set. [TypeScript] FormData can only imported when esModuleInterop flag is set. May 31, 2020
@jdalrymple
Copy link

What is the reason for the separate export anyways?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants