-
Notifications
You must be signed in to change notification settings - Fork 1
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
What is this for? #5
Comments
mints is most important for memory footprint and time to first compile for running on a browser. I built this for a couple of uses.
This is an extreme case, but even if compiling with raw ts + mints and running in a production environment, if the tool is running on mints, it will work to some extent without problems. (Although there is the problem of using user CPU resources unnecessarily.) In terms of footprint, esbuild has some problems.
mints also has problems.
|
Wow, thanks for the in-depth answer. fwiw, I think the tradeoffs you've had to make, like no ASI, are completely reasonable - these are things you could easily lint against with a standard linter anyhow. (This is a really good answer - you might consider including this in the README. 🙂) |
Just wondering, what did you build this for?
I went looking for a tiny TS compiler that would be small and fast enough to run in the browser - perhaps in a service worker.
Is that what you're after as well?
I wonder, esbuild being the fastest thing out there, would it be possible to pull just the parser and transformer from it's libraries, build a WASM module using tinygo, and get something very fast and small?
With those compile times, and if it runs on a separate thread from the UI thread (in a service worker) it might not actually impact load times substantially.
You might not need to write an entirely new parser. Seems like a lot of work. So much hard work went into esbuild already, and expect it might be both small and fast if built with tinygo, as the parser itself is hand written and small.
What do you think?
The text was updated successfully, but these errors were encountered: