1.6.0 • Published 5 years ago

@dot-store/fs v1.6.0

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

@dot-store/fs

Filesystem operations with dot-store.

beavis

Install

npm install --save dot-event dot-store @dot-store/fs

Usage

import dotEvent from "dot-event"
import dotStore from "dot-store"
import fs from "@dot-store/fs"

const events = dotEvent()
const store = dotStore(events)

fs({ events, store })

const id = Math.random()
const path = `${__dirname}/id.json`

await events.fs("writeJson.test", { json: { id }, path })
store.get("fs.writeJson.test").success // true

await events.fs("readJson.test", { path })
store.get("fs.readJson.test.id") // id
1.6.0

5 years ago

1.5.0

5 years ago

1.4.0

6 years ago

1.3.0

6 years ago

1.2.0

6 years ago

1.1.0

6 years ago

1.0.0

6 years ago