Skip to content

Developer environment setup

Wade Baglin edited this page Sep 3, 2016 · 3 revisions

This page details a typical developer environment setup. Although VS Code is used as the reference IDE, these notes and instructions should carry over with little modification to most typical node js developer environments setups.

As a general rule, no reliance (dependency) has been made with any specific IDE feature or IDE extension.

Linting

In addition to [the coding standards](coding standards), this project uses the node-style-guide ((NPM Package) for source styling.

IDE Support

  • VS Code - ESLint extenions
  • Note: Once installed, the plugin references the .eslintrc.js file for settings

CLI

To use eslint from the command line, a global install of eslint is required. One may do this with the following NPM command:

npm install -g eslint

To get eslint to provide feedback for the source file, the following command can be executed:

eslint {path to your js file}

Formatting

This project uses the js-beautify (NPM Package) for source formatting.

IDE Support

  • VS Code - beautify extension
  • Note: This extension does not contain a key-binding by default. Details for how to edit/add one can be found here.
  • To use: in the file you want to beautify, press the F1 key and type beautify in the command box.

NPM script

To beautify the whole solution, the beautify-solution NPM script is available for use. To execute this script the following NPM command can be used:

npm run beautify-solution

CLI

To beautify a source code file from the command line, the following command can be used:

js-beautify -f {path to file} ----config {path to .jsbeautifyrc}

IntelliSense (Auto-complete)

For IDEs or text editors that support IntelliSense (Auto-complete), the following NPM command is recommend to be run in order to supply the correct javascript type definitions.

npm install -g typings

typings install dt~node --global

typings install dt~express dt~serve-static dt~express-serve-static-core --global

Read more about typings and VS Code [here](typings install dtnode --global typings install dtexpress dtserve-static dtexpress-serve-static-core --global).

Other general developer links

Node

VS Code IDE

NPM

Home

User Documentation

Buzzer Click Docs

[Developer environment setup](Developer environment setup)

[Coding standards](Coding standards)

Clone this wiki locally