Simple JavaScript IDE

前端 未结 4 2007
猫巷女王i
猫巷女王i 2021-02-05 20:45

I am brand new to JavaScript and I would like practice my skills using a simple windows based IDE. While learning I do not want to use any CSS or HTML. I would like if possible

相关标签:
4条回答
  • 2021-02-05 21:00

    Have a look at either,

    • WebStorm: real JavaScript IDE (possibly the best.)
    • Sublime Text 2: text editor with syntax highlighting, and possibility to install plugins.

    You can use either software, together with node.js, to get what you want.

    Executing the file,

    function squareNumber(x) {
        return x * x;
    }
    
    console.log(squareNumber(5));
    

    with node.js will output,

    25
    
    0 讨论(0)
  • 2021-02-05 21:09

    Besides the options listed in the answers above; these are additional options I use when I need to write/test JS without HTML/CSS :

    1) Firefox Developer Edition - ScratchPad

    The Firefox Developer Edition browser offers a good console with all the necessary features to write JavaScript.

    To cite a specific feature - ScratchPad provides you with a good option to write JS code and you can use the run button to view it on the console.

    As you can see below it has the syntax coloring and even the options to save and open files directly from your computer.

    You can open the Firefox ScratchPad as an independent window using the shortcut - SHIFT+F4

    It features code completion, inline documentation and much more, you can learn more about using it from the official documentation here - https://developer.mozilla.org/en-US/docs/Tools/Scratchpad

    Keyboard Shortcuts

    CTRL + L - To display selected code

    CTRL + SPACE - Code Hinting

    CTRL + R - Run Command

    CTRL + I - Inspect Command

    2) Node CMD or CMD + Node

    I also like using node + CMD since they work seamlessly. For this option, you need to install node.js and use the CMD to write and test your JS code.

    You can also consider using the node.js CMD that works like the windows CMD.

    You can change the background color and the text color of the Node CMD by clicking on the top bar and choosing properties

    For syntax coloring on Node when using node, you can add one of the syntax coloring npm packages as illustrated below :

    I installed the cli-color npm package in these four steps :

    1) Check if npm is installed using the nmp -v

    2) Install your preferred package using npm install <name of package>

    3) Include the package

    4) Test the package and view the results

    NOTE: It important to check out the documentation of each package esp on the usage since there may be differences.

    These are two of my favorite Node.js syntax highlighting packages :

    https://www.npmjs.com/package/cli-color and https://www.npmjs.com/package/cli-highlight

    0 讨论(0)
  • 2021-02-05 21:10

    Ended up using this IDE as I could run it on a low powered Laptop. Free Version

    http://brackets.io/

    There is also a free offering from Microsoft with Visual Studio 2015 called "Visual Studio Code" runs on Macs and linux too. Only used it for a day but it work great on my low powered tablet.

    https://code.visualstudio.com/

    0 讨论(0)
  • 2021-02-05 21:18

    There are a lot of good online IDEs at the moment. One of my favorites is JSFiddle, but you said you don't want to use CSS and HTML so it's superfluous in this case. You can use JSBin, opening only the Javascript and Console panels. Another very good one is, in my opinion, Ideone, which has a lot of languages(for JS you have to select Javascript Spidermonkey). The last one I suggest you is JSConsole, from the creator of JSBin, which is basically an enhanced Javascript console(as the name states).

    0 讨论(0)
提交回复
热议问题