6.3.3 • Published 3 years ago

@types/keystonejs__adapter-knex v6.3.3

Weekly downloads
1,511
License
MIT
Repository
github
Last release
3 years ago

Installation

npm install --save @types/keystonejs__adapter-knex

Summary

This package contains type definitions for @keystonejs/adapter-knex (https://github.com/keystonejs/keystone).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/keystonejs__adapter-knex.

index.d.ts

// Type definitions for @keystonejs/adapter-knex 6.3
// Project: https://github.com/keystonejs/keystone
// Definitions by: Kevin Brown <https://github.com/thekevinbrown>
//                 Abhijith Vijayan <https://github.com/abhijithvijayan>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 3.5

// Because this is a scoped package, without this line Typescript doesn't associate the
// types with the right package.
// tslint:disable-next-line:no-single-declare-module
declare module '@keystonejs/adapter-knex' {
    import { Raw, Config } from 'knex';
    import { BaseKeystoneAdapter } from '@keystonejs/keystone';

    interface KnexAdaptorOptions {
        knexOptions?: Config | undefined;
        schemaName?: string | undefined;
        listAdapterClass?: any;
        dropDatabase?: boolean | undefined;
    }
    class KnexAdapter extends BaseKeystoneAdapter {
        constructor(options?: KnexAdaptorOptions);

        disconnect(): void;
        dropDatabase(): Promise<Raw>;
    }
}

Additional Details

Credits

These definitions were written by Kevin Brown, and Abhijith Vijayan.