Skip to content

discussion - feasibility to integrate https://wicg.github.io/file-system-access/ #12428

Open
@kaizhu256

Description

@kaizhu256

a serious limitation of downstream libraries like sql.js is inability to persist largish databases (e.g. 1gb) to local filesystem.

that might finally be overcome with newly proposed https://wicg.github.io/file-system-access (note spec's motivation appears mainly saving data in web-editors and ides).
they have an experimental demo here

feasibility question - what additional spec read/write features are needed to integrate emscripten with file-system-access?

spec's current read/write capabilities are (from what i gather):

read

  • await FileSystemHandle.file() // method returns blob/file object

write

  • await FileSystemWritableFileStream.write(data)
  • await FileSystemWritableFileStream.write({ type: "write", data: data })
  • await FileSystemWritableFileStream.write({ type: "write", position: position, data: data })
  • await FileSystemWritableFileStream.write({ type: "seek", position: position })
  • await FileSystemWritableFileStream.write({ type: "truncate", size: size })

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions