haxiomic / dts2hx

Converts TypeScript definition files (d.ts) to haxe externs (.hx) via the TypeScript compiler API
MIT License
131 stars 8 forks source link

TypeScript4 support? #91

Open kevinresol opened 3 years ago

kevinresol commented 3 years ago

Was trying to convert https://github.com/discordjs/discord.js and I think it is using some ts4 features and resulted in a lot of errors:

> Error: Internal error: Reached type-depth limit, stopping further type conversions. This indicates unbound recursive type conversion
> Error: Internal error: Reached type-depth limit, stopping further type conversions. This indicates unbound recursive type conversion
> Error: Internal error: Reached type-depth limit, stopping further type conversions. This indicates unbound recursive type conversion
> Error: Internal error: Reached type-depth limit, stopping further type conversions. This indicates unbound recursive type conversion
> Error: Internal error: Reached type-depth limit, stopping further type conversions. This indicates unbound recursive type conversion
haxiomic commented 2 years ago

Hey, @PXshadow has let me know about downlevel-dts which can translate TS 4 to TS 3.4 syntax, which could help solve these issues in the short term