I’m trying to get the cordova-plugin-file running under Chrome browser, but have no luck at all.
Running in Edge and FF is working fine.
Basically the call to:
window.resolveLocalFileSystemURL(cordova.file.dataDirectory + filename, function (fileSystem)
fails in Chrome with an SECURITY_ERR (code 2). Saying:
It was determined that certain files are unsafe for access within a Web application, or that too many calls are being made on file resources. "name:“SecurityError”
cordova.file.dataDirectory is correctly resolved to filesystem:file:///persistent/
which is mentioned in the Chrome quirks
The app is run by ionic run browser
and I used the Chrome CL option --allow-file-access-from-files but that didn’t change anything. (I guess this option is only relevant when not run from a webserver)
Any advice what can go wrong with Chrome here? 4h solution googling was not helpful.