3 ms·
You can make a virtual file system in the browser using localStorage. You can then sync it across devices and browsers via a server. You can upload files to th
by z3t4 9y ago
You can make a virtual file system in the browser using localStorage. You can then sync it across devices and browsers via a server.
You can upload files to the PWA using drag-n-drop or file input. You can also send files from the PWA to the device file system.
I think it's important that Web browsers can't automatically control the device hard drives, imagine if all web sites you visited would be able to do rm / -rf or scan all files on your hard drive.
- JepZ 9y agoYeah, sure complete access to all files is rediculous. I think more of something like: By default every app has its own directory and the user can (easily) grant an app access to additional directories. That way it can't do much damage and when you trust it, you can give it more access. I use the localStorage as a cache for some of the offline capabilites but as a persistent storage it sucks as you can't easily open the stored "files" with other programms or PWAs.
- BrandoElFollito 9y agoThe private directories is the way Android does it. It is a good idea, provided you can easily allow access to other directories (as you suggested). Unfortunately they missed that second point.