git ssb

0+

cel-desktop / ssb-pkg



Tree: d456a6cc8589489e558e6164750474ed2cfc961e

Files: d456a6cc8589489e558e6164750474ed2cfc961e / test / test-79-npm / nedb / nedb.js

351 bytesRaw
1'use strict';
2
3var Nedb = require('nedb');
4var fs = require('fs');
5var filename = 'database.db';
6var db = new Nedb({ filename: filename });
7
8db.loadDatabase(function (error) {
9 if (error) throw error;
10 db.insert([ { a: 5 }, { a: 42 } ], function (error2) {
11 if (error2) throw error2;
12 fs.unlinkSync(filename);
13 console.log('ok');
14 });
15});
16

Built with git-ssb-web