判断目录是否存在: if(!fs.existsSync(path)){ // 如果目录不存在,则创建 fs.mkdirSync(path); } 文件写入: fs.writeFile(filePath,'12…
分类:Node
node.js将word转html 转
转自:https://www.jianshu.com/p/cc8f9b9cb93c var mammoth = require('mammoth'); const fs = require('fs'); const _ …
node child_process模块 转
转自:https://blog.csdn.net/canot/article/details/72566702 NodeJs是一个单进程的语言,不能像Java那样可以创建多线程来并发执行。当然在大部分情况下,NodeJs…