News for hackers. Stuff that matters.
Re:Compiling JSX with Sweet.js using Readtables by skrebbel on Wednesday July 02, 2014 @03:49PM (#7979248)
Wow! I cannot wait to convert my React code to this. Awesome!

As a complete macro noob, I'm starting to wonder whether readtables would also allow all of TypeScript to be compiled with sweetjs. Or at least transformed, without type checking.

Re:Compiling JSX with Sweet.js using Readtables by disnet on Wednesday July 02, 2014 @04:29PM (#7979532)
> I'm starting to wonder whether readtables would also allow all of TypeScript to be compiled with sweetjs.

I haven't tried yet but I think all the syntax forms in TypeScript can be handled with just plain sweet.js macros, no need for the readtable. Actually handling the types in TypeScript via macros should also be eventually possible (Typed Racket [1] does typing via macros) once we have a bit more feature parity with Racket's macro system.

[1] http://docs.racket-lang.org/ts-guide/index.html?q=typed

Re:Compiling JSX with Sweet.js using Readtables by dustingetz on Wednesday July 02, 2014 @03:52PM (#7979267)
I don't think you have to convert anything, it should just work by replacing the react build step with sweetjs's build step, though he does say that it isn't heavily tested yet
Re:Compiling JSX with Sweet.js using Readtables by skrebbel on Wednesday July 02, 2014 @04:00PM (#7979324)
yeah, that's really all i mean. but our frontend build setup looks like it was made by people who have no clue what they're doing (me, at the time), which might make it slightly more involved than you might expect :-)
Re:Compiling JSX with Sweet.js using Readtables by jlongster on Wednesday July 02, 2014 @04:06PM (#7979365)
Thanks! I personally prefer gulp, and you can use https://github.com/jlongster/gulp-sweetjs. It makes it really easy to integrate (that isn't the one published in npm, I'm working on that). There's also a grunt loader: https://github.com/natefaubion/grunt-sweet.js, although that hasn't been updated to support readtables yet.