8000 Try sucrase as babel alternative · Issue #40 · unjs/jiti · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Try sucrase as babel alternative #40

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 8000 to your account

Closed
pi0 opened this issue Sep 14, 2021 · 5 comments
Closed

Try sucrase as babel alternative #40

pi0 opened this issue Sep 14, 2021 · 5 comments

Comments

@pi0
Copy link
Member
pi0 commented Sep 14, 2021

https://github.com/alangpierce/sucrase

@timofei-iatsenko
Copy link

i think SWC would be a better choice because unlike sucrase it's extendable and part of the features already enabled in this project supported in SWC and not supported in sucrase (emitDecoratorMetadata f .ex)

And i don't belive that JS compiler might be faster than Rust's SWC or esbuild...

@pi0
Copy link
Member Author
pi0 commented Mar 15, 2023

I guess with more babel deps and it's acceptable perf won't worth focusing on this.

@pi0 pi0 closed this as completed Mar 15, 2023
@PAXANDDOS
Copy link
PAXANDDOS commented Apr 29, 2023

I strongly agree with @thekip. The SWC community is rising fast, and I'm glad Rust-based stuff gets accepted quickly. SWC should be more comfortable to use.
I don't know but maybe the bundle size would decrease too. Sorry if I'm wrong. Because currently compiled dist/babel.js is about to reach 2 MB. Tailwind started using Jiti recently, released an update, and its chart on bundlephobia jumped to the skies. When it doesn't really matter for tailwind, because it's being used in devDeps anyways, it matters tools that require Jiti for production (such as @lingui/macro)

@pi0 pi0 reopened this May 3, 2023
@pi0
Copy link
Member Author
pi0 commented May 3, 2023

I am open to experimenting! We could try an experimental build jiti/surcase via optional surcase peer dependency.

@timofei-iatsenko
Copy link

offtopic:

it matters tools that require Jiti for production (such as @lingui/macro)

I'm as an contributor of @lingui/macro could say that it also doesn't matter, because macro executed in the compile time and jiti is not going to the bundle.

@pi0 pi0 closed this as not planned Won't fix, can't repro, duplicate, stale Sep 12, 2024
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

3 participants
0