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

Pretokenise JS functions included with generate_js #2461

Open
gfwilliams opened this issue Jan 30, 2024 · 0 comments
Open

Pretokenise JS functions included with generate_js #2461

gfwilliams opened this issue Jan 30, 2024 · 0 comments

Comments

@gfwilliams
Copy link
Member

Right now, in scripts/build_jswrapper.py we just include the JS files as-is

However we could pretokenise them and make them run faster as well as saving some space.

Only issue is our tools for pretokenising are either in JS or C, not Python (and I don't think we require Node.js to be installed for a compile currently), so I guess maybe we'd have to either:

  • Have a tool written in C that uses jslNewTokenisedStringFromLexer then build and run that from scripts/build_jswrapper.py
  • Pre-compile all the JS files we use (a bit like we pre-minify currently)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant