I am aware that the HTML5 Filesystem API gives you access to a sandboxed file system. Let’s say I write a file to the filesystem. Is it possible to let the user save that file to their actual file system? I would like to be able to tell the user where the file is written so that they may access it but that does not seem to be possible.
My only idea is to read the file as a data url and make a hyperlink that the user can save, but that has scalability issues in terms of file size.
You can use the URL obtained from the
toURLmethod as the value for a link’s href attribute, which link in addition has adownloadattribute. Clicking on the link will then prompt the user to save the contents on her filesystem.