Socket
Book a DemoInstallSign in
Socket

fs-resolver-fs

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fs-resolver-fs

resolves file urls

latest
Source
npmnpm
Version
7.0.1
Version published
Maintainers
1
Created
Source

styled with prettier Known Vulnerabilities Commitizen friendly npm License minified size downloads GitHub Issues Build Status codecov.io Coverage Status Greenkeeper semantic-release

fs-resolver-fs

resolves file urls

API

Table of Contents

FileScheme

Extends URLScheme

URLScheme for file system access

get

Creates a readable stream for the content of th file associated to a given file URL

Parameters

  • context Context execution context
  • url URL of the a file
  • options (Object | string) passed as options to fs.createReadStream()

Returns ReadableStream of the file content

stat

Read stat of a file assiciated to a given file URL

Parameters

  • context Context execution context
  • url URL of the a file
  • options Object unused for now

Returns (Object | Error) as delivered by fs.stat()

put

Put content of a stream to a file associated to a given file URL

Parameters

  • context {Context} execution context
  • url {URL} of the a file
  • stream {Stream} data source
  • options (Object | string) passed as options to fs.createWriteStream()

Returns (undefined | Error) if url is not a file url

delete

Deletes the file assiciated to a given file URL

Parameters

  • context Context execution context
  • url URL of the a file

Returns (Object | Error) as delivered by fs.unlink()

list

List content of a directory

Parameters

  • context Context execution context
  • url URL of the a directory
  • options Object unused for now

Returns Iterator

name

Scheme name if 'file'

Returns string 'file'

install

With npm do:

npm install fs-resolver-fs

license

BSD-2-Clause

Keywords

url

FAQs

Package last updated on 08 Jan 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts