Skip to content

AbstractFS/node-abstractfs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Node Abstract Filesystem

A very basic and experimental filesystem wrapper for node, allowing the same interface to be used across multiple filesystem implementations.

Currently only supports Local, but should be easy enough to extend. It is also highly untested, so use it at your own risk. That being said, if you notice any issues feel free to open an issue or fix it and make a pull request.

Installation

npm install abstractfs

Features

  • Promises via bluebird
  • Prefixing of paths
  • One unified API for every filesystem type, no worrying about special packages

Example

const AbstractFS = require('abstractfs');

const filesystem = new AbstractFS.Filesystem(new AbstractFS.Adapters.Local('./'));

filesystem.write('test.txt', 'Testing data').then(() => console.log('Written!')).catch((e) => console.log(e, e.stack));

Credits

This module was heavily inspired by and follows the API of Flysystem.

About

A proof of concept abstract filesystem for node using promises

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published