nodeJs的模块依赖
2021-07-02 12:05
阅读:551
标签:blog 路径 需要 后缀 nod nodejs ejs rip script
1、require载入依赖
var http = require(‘http‘);//http为路径,可以忽略后缀
2、exports输出依赖
exports.add=add;//add为方法
3、只需要在载入依赖的页面引用方法就可以
nodeJs的模块依赖
标签:blog 路径 需要 后缀 nod nodejs ejs rip script
原文地址:http://www.cnblogs.com/huangqiming/p/7127732.html
下一篇:CSS-选择器
评论
亲,登录后才可以留言!