Sorry to anyone if this has already been posted about. I couldn't find anything, so I'm typing this with the assumption that no one's said anything about this.
While experimenting with JavaScript, I noticed that Snap doesn't have any way to run a command, such as this:
alert('Hello world!')
as there's only a reporter block to run an anonymous function. Sure, you can call a function that runs the alert object, but you can't call it using a command block easily. Run and launch only accept command blocks in their rings, and if you try to put a call reporter to run the command, it just lags your page out.
You can's use the report block because that skips the rest of the script and ignores any loops you might have.
GOOD NEWS! I've figured out a way to contradict my own words. There is an easy way to run a JavaScript function as a command.
I'm sure there's someone that could figure out how to make this into a custom block that accepts inputs for the parameters for the function, the code, and the arguments. I've tried, but I don't think I quite understand Snap enough to get it to work.
Let me know your thoughts!