10、第一个vue-cli项目
常见DOS命令
- hello.js
// 暴露一个方法
exports.sayHi= function () {
document.write("<h1>狂神说ES6</h1>");
}
- main.js
var hello = require("./hello")
hello.sayHi();
- webpack.js
module.exports = {
entry: './modules/main.js',
output: {
filename:"./js/bundle.js"
}
}