-
Notifications
You must be signed in to change notification settings - Fork 10
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
Add a compiler from scrapscript to JS #90
base: trunk
Are you sure you want to change the base?
Conversation
@@ -1254,6 +1255,91 @@ def bencode(obj: object) -> bytes: | |||
raise NotImplementedError(f"bencode not implemented for {type(obj)}") | |||
|
|||
|
|||
class JSCompiler: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🙏 you know what I'm thinking
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
imports are our friends
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is just a prototype before doing it in scrap
This is a hacky prototype but shows how easy it would be to compile scrapscript->JS in scrapscript. Once I get tests for this working I would like to re-write in scrapscript and land that instead.