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

0.0.36 • Public • Published

Installation

npm install --save @types/level-sublevel

Summary

This package contains type definitions for level-sublevel (https://github.com/dominictarr/level-sublevel).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/level-sublevel.

index.d.ts

import * as levelup from "levelup";

export = sublevel;

declare var sublevel: sublevel.Constructor;

declare namespace sublevel {
    interface Hook {
        (ch: any, add: (op: Batch | boolean) => void): void;
    }

    interface Batch extends levelup.Batch {
        prefix?: Sublevel | undefined;
    }

    interface Sublevel extends levelup.LevelUpBase<Batch> {
        sublevel(key: string): Sublevel;
        pre(hook: Hook): Function;
    }

    type Constructor = (levelup: levelup.LevelUp) => Sublevel;
}

Additional Details

  • Last updated: Tue, 07 Nov 2023 09:09:38 GMT
  • Dependencies: @types/levelup

Credits

These definitions were written by Bas Pennings.

Versions

Current Tags

Version History

Package Sidebar

Install

npm i @types/level-sublevel

Weekly Downloads

94

Version

0.0.36

License

MIT

Unpacked Size

3.7 kB

Total Files

5

Last publish

Collaborators

  • types