@types/crypto-pouch
TypeScript icon, indicating that this package has built-in type declarations

4.0.4 • Public • Published

Installation

npm install --save @types/crypto-pouch

Summary

This package contains type definitions for crypto-pouch (https://github.com/calvinmetcalf/crypto-pouch).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/crypto-pouch.

index.d.ts

import PouchDB = require("pouchdb");

declare global {
    namespace PouchDB {
        namespace CryptoPouch {
            interface Options {
                /* A string password, used to encrypt documents. */
                password: string;
                /* Array of strings of properties that will not be encrypted. */
                ignore?: string[];
            }
        }

        interface Database {
            /**
             * @param options see CryptoPouch.Options
             */
            crypto(options: CryptoPouch.Options): Promise<void>;
            /**
             * @param password A string password, used to encrypt documents.
             * @param ignore Array of strings of properties that will not be encrypted.
             */
            crypto(password: string, ignore?: string[]): Promise<void>;
            /**
             * Disables encryption on the database and forgets your password.
             */
            removeCrypto(): void;
        }
    }
}
declare const Plugin: PouchDB.Plugin;
export = Plugin;

Additional Details

  • Last updated: Mon, 06 Nov 2023 22:41:05 GMT
  • Dependencies: @types/pouchdb

Credits

These definitions were written by .

Readme

Keywords

none

Package Sidebar

Install

npm i @types/crypto-pouch

Weekly Downloads

46

Version

4.0.4

License

MIT

Unpacked Size

4.56 kB

Total Files

5

Last publish

Collaborators

  • types