file-attributes
v1.0.3
Published
Just a simple per-file attributes system
Downloads
1
Maintainers
Readme
Per file attributes
Just a simple per-file attributes system
var kv = require('file-attributes');
var attributes = kv("/path/to/disk"); // where to store
attributes.set("/home/user/documents/file.txt", JSON.stringify({
ready: true,
signed: false
}), function(err, data) {
// on success/failure
});
attributes.get("/home/user/documents/file.txt", (err, data) => {
if (err) {
// fail
}
data = JSON.parse(data);
});