Usually this would be done in Dev Tools’ console, but you can also create a simple Node.js build system and get results without having to leave Sublime.
Let’s get ready
You will need to have Node installed, if you don’t simply head over to their website and run it using the default settings.
Go to “Tools ➜ Build System ➜ New Build System” in the menu bar. Paste this replacing everything in the new tab that has opened:
"cmd": ["node", "$file"],
- Save this file as “node.sublime-build” in the default “user” folder. Your build system is ready!
Go to “Tools ➜ Build System” in the menu bar and select “node”, the build system that you’ve just created.
Have a question about this post, a project or anything else?
Let's have a conversation on Twitter.