Giter Site home page Giter Site logo

vscode-npm-scripts's Introduction

Node npm

This extension supports running npm scripts defined in the package.json file and validating the installed modules against the dependencies defined in the package.json.

Notice The validation is done by running npm and it is not run when the modules are managed by yarn.

The package.json validation reports warnings for modules:

  • that are defined in the package.json, but that are not installed
  • that are installed but not defined in the package.json
  • that are installed but do not satisfy the version defined in the package.json.

Quick fixes to run npm are provided for reported warnings.

package.json validation

Commands for running scripts are available the npm category.

command palette

  • Run npm install, also available in the context menu of the explorer when the `package.json file
  • Run a script (npm run-script) defined in the package.json by picking a script defined in the scripts section of the package.json.
  • Rerun the last npm script you have executed using this extension.
  • Terminate a running script

The scripts can be run either in the integrated terminal or an output window.

Settings

  • npm.validate.enable validate the dependencies in the package.json file, the default is true.
  • npm.runInTerminal defines whether the command is run in a terminal window or whether the output form the command is shown in the Output window. The default is to show the output in the terminal.
  • npm.includeDirectories define additional directories that include a package.json.
  • npm.useRootDirectory define whether the root directory of the workspace should be ignored, the default is false.
  • npm.runSilent run npm commands with the --silent option, the default is false.
  • npm.bin custom npm bin name, the default is npm.
Example
{
	"npm.runInTerminal": false,
	"npm.includeDirectories": [
		"subdir1/path",
		"subdir2/path"
	]
}

Keyboard Shortcuts

The extension defines a chording keyboard shortcut for the R key. As a consequence an existing keybinding for R is not executed immediately. If this is not desired, then please bind another key for these commands, see the customization documentation.

vscode-npm-scripts's People

Contributors

egamma avatar gigitsu avatar bernardop avatar scytalezero avatar ppluciennik avatar rrdelaney avatar chrisdias avatar gpbl avatar azz avatar atian25 avatar

Watchers

zhangaz1 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.