Skip to content

Support higher order (async) functions in VFS adapters #34

@andersevenrud

Description

@andersevenrud

Right now the higher order functions look like this:

const adapter = (core) => {
  return {
    readdir: vfs => async (path, options) => {},
    // ...
  }
}

It would be nice to have the following option:

const adapter = (core) => {
  return async (vfs) => { // async optional
    readdir: async (path, options) => {},
    // ...
  }
}

As well as:

This is supported as of 2020-07-22

const adapter = async (core) => {
 // ...
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions