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

Is Sucrase support targeting ES3? #832

Closed
aztack opened this issue Mar 13, 2024 · 1 comment
Closed

Is Sucrase support targeting ES3? #832

aztack opened this issue Mar 13, 2024 · 1 comment

Comments

@aztack
Copy link

aztack commented Mar 13, 2024

I'm writing plugin targeting a rather old JavaScript engine which support only ES3 syntax.

I've tried compile my *.ts to es3 with TypeScript which have no problem. But I want to try do the compiling on-the-fly which will much ease the building process.

So, is Sucrase support targeting to ES3?

@aztack aztack changed the title Is Sucrase support targting to ES3? Is Sucrase support targeting ES3? Mar 13, 2024
@alangpierce
Copy link
Owner

Hi, sorry for the delay. No, Sucrase doesn't support targeting ES3. It supports a few ES transforms for past pragmatic reasons, but generally isn't meant for targeting old browsers. For compiling on-the-fly, you could look at ts-node or related tools, which can work with the official TypeScript compiler or other compilers.

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