Open
Description
My understanding of allowSyntheticDefaultImports
is that it assumes you have an extra build step that converts imports of the form import React from "react";
to import * as React from "react";
(so you can write the former in place of the latter).
However, by default Node does not do this natively. This can cause runtime errors when importing packages that haven't reexported everything as a default.
Also see:
esModuleInterop: true
cause runtime error microsoft/TypeScript#41898 (comment)- allowSyntheticDefaultImports doesn't work in TypeScript > 1.8.0 microsoft/TypeScript#7518 (comment)
I'm not fully confident about this - would be keen for others to weigh in whether this assessment is accurate.
Metadata
Metadata
Assignees
Labels
No labels