Exported TypeScript types are all wrong
stevenpetryk opened this issue · comments
Steven Petryk commented
Parcel seems to be rolling up all exported TypeScript types into the mafs
module. So you can write code like this:
import { OfY } from "mafs"
<OfY ... />
And TypeScript doesn't show any errors, but in reality, OfY
is undefined at runtime (the correct way to use OfY
is to import Plot
and then use Plot.OfY
).
To fix this, I've confirmed that API extractor does a better job at doing .d.ts rollup, so now I just have to figure out how to disable Parcel's type rollup.