05-前端模块化开发
简介
CommonJS规范
// 定义成员:
const sum = function(a,b){
return a + b
}
const subtract = function(a,b){
return a - b
}
const multiply = function(a,b){
return a * b
}
const divide = function(a,b){
return a / b
}ES6模块化规范
ES6模块化写法2
最后更新于
这有帮助吗?
