How to Create a Javascript Console in Sublime Text

Download the Node installer from the project's homepage and run it., Go to "Tools > Build System > New Build System" in the top bar. , Paste this code into the resulting new tab that Sublime Text opened, replacing anything else in it: { "cmd"...

13 Steps 1 min read Medium

Step-by-Step Guide

  1. Step 1: Download the Node installer from the project's homepage and run it.

    Simply use the default settings.,, To do this, open terminal and run "which node".

    This will print out the path to the node binary. , Now you have created your build system! ,, This is the build system that you just created., A console will now appear in a pane at the bottom of the window, showing the results of your script!
  2. Step 2: Go to "Tools > Build System > New Build System" in the top bar.

  3. Step 3: Paste this code into the resulting new tab that Sublime Text opened

  4. Step 4: replacing anything else in it: { "cmd":

  5. Step 5: "selector": "source.js" } If you receive a "" error

  6. Step 6: then you'll need to change "node" in the code above to the path where node is located.

  7. Step 7: Save the file as "node.sublime-build" in the default "user" folder.

  8. Step 8: Open the Javascript file that you want to run in Sublime Text.

  9. Step 9: Go to "Tools > Build System" in the top bar and select "node".

  10. Step 10: Build the Javascript file

  11. Step 11: using either the build shortcut (Ctrl+B for Windows

  12. Step 12: and ⌘ Command+B for Mac)

  13. Step 13: or by choosing "Build" from the "Tools" menu.

Detailed Guide

Simply use the default settings.,, To do this, open terminal and run "which node".

This will print out the path to the node binary. , Now you have created your build system! ,, This is the build system that you just created., A console will now appear in a pane at the bottom of the window, showing the results of your script!

About the Author

A

Angela Scott

Enthusiastic about teaching pet care techniques through clear, step-by-step guides.

45 articles
View all articles

Rate This Guide

--
Loading...
5
0
4
0
3
0
2
0
1
0

How helpful was this guide? Click to rate: