Reputation: 145
How do you run Javascript program like
function foo() {
alert('foo');
}
foo();
without an html file like you can do in jsfiddle. Can you do that in an editor?
Upvotes: 0
Views: 86
Reputation: 81
You have several options:
EDIT: If you're on MacOS, this might help you even more: https://www.quora.com/How-do-I-run-my-JavaScript-code-in-Sublime-Text-console
Upvotes: 1