appendFile is not a function?

发布于 7 年前作者 jiezeng4233 次浏览最后编辑 7 年前来自 issues

FileSystemManager.appendFile(Object object)

使用如上方法给本地文件追加内容,提示fs.appendFile is not a function; 

FileSystemManager.appendFileSync(string filePath, string|ArrayBuffer data, string encoding)

使用fs.appendFileSync 也是提示fs.appendFileSync is not a function;

FileSystemManager.writeFile(Object object)

使FileSystemManager.writeFile(Object object) 就可以,请问为什么呢?有了解的朋友吗?


另外在问个问题,写入文件时,如何换行?

下图提示fs.appendFile is not a function

下图提示fs.appendFileSync is not a function

下图正常写入本地文件


1 回复
tzhu
tzhu1 楼5 年前

看起来是和基础库的版本有关。