https://github.com/futurus/fastify-nedb
Fastify NeDB plug-in
https://github.com/futurus/fastify-nedb
database fastify nedb plug-in
Last synced: 4 months ago
JSON representation
Fastify NeDB plug-in
- Host: GitHub
- URL: https://github.com/futurus/fastify-nedb
- Owner: futurus
- License: mit
- Created: 2018-09-20T23:26:34.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2023-06-21T14:09:38.000Z (almost 3 years ago)
- Last Synced: 2025-10-03T15:12:04.022Z (8 months ago)
- Topics: database, fastify, nedb, plug-in
- Language: JavaScript
- Homepage:
- Size: 844 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Fastify NeBD Plugin
[](https://standardjs.com) [](https://travis-ci.org/futurus/fastify-nedb) [](https://snyk.io/test/github/futurus/fastify-nedb?targetFile=package.json) [](https://greenkeeper.io/)
## Installation
```npm
npm install fastify-nebd --save
```
## Usage
```javascript
fastify.register(require('fastify-nedb'), {
dataStores: ['user']
}, err => console.error(err))
fastify.get('/', (request, reply) => {
console.log(fastify.db.user) // NeDB persistence saved to dataFolder/user.db
})
```
## Options
Options object.
```javascript
{
dataFolder: 'folder' // default to 'data'
dataStores: ['store1', 'store2'] // must be specified
}
```
See [NeDB](https://github.com/louischatriot/nedb) for more details.
## Author
[Alex Vu Nguyen](vu@vnguyen.io)
## License
Licensed under [MIT](./LICENSE).