Bug 213775 - [Feature Request] Implement the File System Access API (née Native File System API)
Summary: [Feature Request] Implement the File System Access API (née Native File Syste...
Status: RESOLVED DUPLICATE of bug 231706
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-30 00:34 PDT by Thomas Steiner
Modified: 2022-02-15 14:10 PST (History)
7 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Comment 1 Thomas Steiner 2021-03-12 08:50:25 PST
The API has been renamed to “File System Access API”.
Comment 2 Ashley Gullen 2021-03-13 04:35:16 PST
I'd like to add my support for this based on the demand for it from users of our browser-based game editor Construct 3 (www.construct.net).

We provide a few save options, including cloud save to Google Drive, OneDrive and Dropbox, saving to browser storage, downloading a copy, and where supported, saving to local files and folders with the File System Access API.

Our data shows the file system save options are the most popular of all these options. I believe this demonstrates that it's actually what users want and is their preferred way of saving work from the web. (This probably also makes it an incentive for people to choose a browser that does support it.)
Comment 3 Syed Riyaz Uddin 2021-05-30 10:55:24 PDT
Especially with the advent of Progressive Web Apps, FileSystem API seems like a necessary feature that'd help make PWAs completely offline. I tried FileSystem API with my client's E-Learning platform and it works smooth. I just wish that other browsers (Firefox and Safari) would implement it.
Comment 4 Thomas Steiner 2021-12-22 23:48:04 PST
I have documented two use cases for the showOpenFilePicker() and the showSaveFilePicker() methods of this API (and one could easily extend these apps to support showDirectoryPicker() as well:

https://web.dev/excalidraw-and-fugu/#working-with-files for https://excalidraw.com/ and https://web.dev/svgcode/#file-system-access-api for https://svgco.de/.
Comment 5 jdscheff 2022-02-15 12:03:55 PST
For https://basketball-gm.com/ (video game with tens of thousands of active users) I store a ton of data in IndexedDB. If users want to export it, the File System Access API and showSaveFilePicker is the only good way to stream client side data to a file. Otherwise, I need to either read it all into memory first (not feasible for large data) or use a complicated workaround like https://github.com/jimmywarting/StreamSaver.js

So currently it is possible to create files client side, if you read the data into memory first. And it is possible to create arbitrarily large files from streaming data, as long as you use a complicated workaround. showSaveFilePicker lets you accomplish the same thing with no complicated workaround.

I understand showSaveFilePicker enables more functionality than just streaming data to a new file... but I am not aware of any alternative proposal that would allow easily streaming data to a new file. So I hope browsers besides Chrome can either support showSaveFilePicker or come up with some feasible alternative.
Comment 6 Jen Simmons 2022-02-15 14:09:42 PST

*** This bug has been marked as a duplicate of bug 231706 ***
Comment 7 Jen Simmons 2022-02-15 14:10:52 PST
Thanks for your comments, everyone. I'm marking this a duplicate of the ticket that's tracking this work as it's happening. 

This article we published this week will be of interest to you: https://webkit.org/blog/12257/the-file-system-access-api-with-origin-private-file-system/