Node Installation Webpack

Source: Internet
Author: User
Tags install node

To install node. JS First, node. JS has its own package Manager Npm,webpack needs support for node. JS v0.6 above, it is recommended to use the latest version of node. js.

Install Webpack with NPM:

$ npm install webpack -g

At this point the Webpack has been installed in the global environment, you can try it through the command line webpack -h .

Typically, we install Webpack into a project's dependencies so that we can use the Webpack of the project's local version.

# 进入项目目录# 确定已经有 package.json,没有就通过 npm init 创建# 安装 webpack 依赖$ npm install webpack --save-dev

Webpack currently has two major versions, one in the master backbone of the stable version, one in the Webpack-2 branch of the beta, Beta has some experimental features and is incompatible with the stable version, in the official project should use stable version.

# 查看 webpack 版本信息$ npm info webpack# 安装指定版本的 webpack$ npm install [email protected]1.12.x --save-dev

If you need to use the Webpack development tool, install it separately:

$ npm install webpack-dev-server --save-dev

Node Installation Webpack

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.