摘要: // 1.require(path) require('./find.js') //2 require(path) path后缀名省略 require('./find) // 在当前路径下找同名js文件 再找同名js文件夹 // 若找到了 同名文件夹 找文件夹中的index.js //若没有Index.js 就会去当前文件夹中的package.js文件中... 阅读全文
posted @ 2019-07-24 22:22 毛不易的小老婆 阅读(563) 评论(0) 推荐(0)
摘要: const gulp = require('gulp'); const htmlmin = require('gulp-htmlmin'); const fileinclude = require('gulp-file-include') const less = require('gulp-less') const csso = require('gulp-csso') const babel... 阅读全文
posted @ 2019-07-24 02:52 毛不易的小老婆 阅读(147) 评论(0) 推荐(0)
摘要: // shift + 鼠标右键 在文件夹中可快捷打开 cmd // clear 清除 // node.js中规定一个JavaScript文件就是一个模块 模块内定义的变量和函数外部无法得到 //模块内部 使用exports对象进行成员导出 使用require方法导入其他模块 // node.js本质上是模块化的依赖开发 ... 阅读全文
posted @ 2019-07-24 00:08 毛不易的小老婆 阅读(268) 评论(0) 推荐(0)