1.本地缓存文件只能通过 FileSystemManager.saveFile() 接口将本地临时文件保存获得。
引用网页:https://developers.weixin.qq.com/miniprogram/dev/framework/ability/file-system.html
2.每个微信小程序都可以有自己的本地缓存,可以通过 wx.setStorage/wx.setStorageSync等API对本地缓存进行读写和清理。
引用网页:https://developers.weixin.qq.com/miniprogram/dev/framework/ability/storage.html
以上两种说法,到底是哪个对?
1.本地缓存文件只能通过本地临时文件保存获得?
2.本地缓存文件可以通过wx.setStorage等API对本地缓存进行读写和清理?
本地缓存(数据缓存)和本地缓存文件(文件系统)是两种存储机制