Skip to content

Entries: define the relative path of a File #237

Open

Description

@annevk

The webkitRelativePath getter carried over from the File and Directory Entries API in #222 returns "this's relative path, or the empty string if not specified". However, File objects don't have a relative path: relative path only defines what a relative path string looks like.

File should get an associated relative path (a relative path or the empty string, initially the empty string), and the getter should return it. It should be exported, so that HTML can set it when files are selected through webkitdirectory.

That raises the question of what the File serialization steps do with it. I believe at least Chromium preserves webkitRelativePath when a File is structured cloned, but this needs checking across implementations, and WPT doesn't seem to test it.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions