javascript - 请教一个package.json相关的问题。
天蓬老师
天蓬老师 2017-04-17 16:33:28
0
4
516
天蓬老师
天蓬老师

欢迎选择我的课程,让我们一起见证您的进步~~

reply all(4)
阿神

It looks like tools/run 应该是主脚本,那么 start should be the parameter of this script

小葫芦

Oh, sorry for the late reply.

What you are looking at is my webpack react seed project code written by imitating kriasoft.

The meaning of this code is to use babel-node to call the run.js script file in the tools directory. The run.js script file calls all build tasks (including functions such as logging), and the last parameter is start. Represents the task of directly calling tools/start.js. The start task is to start the dev server and implement the hot loading function.

阿神

This should be React Starter Kit?

"start": "babel-node tools/run start"

The command will first call tools/run.js, then tools/start.js, and then tools/webpack.config.js

阿神

The npm start command executes the code you wrote in start. For example, if you want to use npm start to run a Nodejs service file, you can change it to start: "node server", which is the same as running node server

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template