-
Notifications
You must be signed in to change notification settings - Fork 54
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
Investigate sweet.js #11
Comments
Maybe minstache would be a sufficient solution here? |
Take a look at this bug/feature request I filed with sweet.js I think as much as possible you want to avoid string concatenation. If you have to do it, write the string concatted functions in a systematic way. With a proper macro system (that also allows runtime code generation), you could use jslint to avoid more errors too. How do you write code for ndarray.js? Are you thinking about what you want the expanded code to look like? Do you write the expanded code first and then write the generating code? I really like the idea of ndarray.js There is some great work here. |
Wait, sorry, I'm getting distracted on code generation for ndarray dependents, not just ndarray itself. Disregard the last comment. |
I'm sure that sweet.js can help this codebase. You can make it a compile time only dependency.
String concatentation to build up functions is very awkward.
With sweet.js you can have regular javascript looking code, and then macros which perform the string concatenation for you at runtime if you are worried about code size. You just shouldn't be dealing with all of these strings, it's incredibly error prone. I'm taking a shot at the conversion.
The text was updated successfully, but these errors were encountered: