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

Improve transpiling efficiency #2

Open
InterLinked1 opened this issue Aug 14, 2022 · 0 comments
Open

Improve transpiling efficiency #2

InterLinked1 opened this issue Aug 14, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@InterLinked1
Copy link
Owner

The recently added on-the-fly transpiling support is very inefficient (hence it being whitelisted on a per-domain basis), and quite honestly overkill for what's needed here: transpiling only nullish coalescing and optional chaining. Babel doesn't seem to support this in the proper way.

As noted on the MSFN forums, there is probably a more efficient way to approach this:

For GitHub exclusively, you may want to have a look at
martok/palefill#29 (comment)
and
https://github.com/dirkf/palefill/commits/df-optchain-patch
https://github.com/dirkf/palefill/releases/tag/v1.19df

The dev(s) use simple transpiling JS code for just those two operators, nothing more (the rest can be handled by polyfills)

Ideally, the transpiling should only analyze for these operators and nothing else.

@InterLinked1 InterLinked1 added the enhancement New feature or request label Aug 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant