lowdb-encrypted-nativescript-adapter
TypeScript icon, indicating that this package has built-in type declarations

0.1.1 • Public • Published

Lowdb Encrypted NativeScript Adapter

A lowdb adapter for using the database from NativeScript apps.

All data will be encrypted before save using a autogenerated secret key.

Installation

Run the following command from the root of your project:

npm install --save lowdb-encrypted-nativescript-adapter

Example

TypeScript

import * as lowdb from "lowdb";
import * as NativeScriptEncryptedAdapter from "lowdb-encrypted-nativescript-adapter";

const adapter = new NativeScriptAdapter('db.json');
const db = lowdb<lowdb.AdapterSync>(adapter);

JavaScript

const lowdb = require("lowdb");
const NativeScriptEncryptedAdapter = require("lowdb-encrypted-nativescript-adapter");

const adapter = new NativeScriptEncryptedAdapter('db.json');
const db = lowdb(adapter);

Based from ludwiktrammer/lowdb-nativescript-adapter

Package Sidebar

Install

npm i lowdb-encrypted-nativescript-adapter

Weekly Downloads

1

Version

0.1.1

License

MIT

Unpacked Size

3.81 kB

Total Files

5

Last publish

Collaborators

  • brunoziie