# @types/node-mongodb-fixtures

> TypeScript definitions for node-mongodb-fixtures

Latest version **3.2.6** (published 2023-11-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/node-mongodb-fixtures
pnpm add @types/node-mongodb-fixtures
yarn add @types/node-mongodb-fixtures
bun add @types/node-mongodb-fixtures
```

## Health

**Score 45/100 (D)** — status: abandoned.

Positive: has types; no vulnerabilities; high maintenance score; popular repo; extremely popular.

Warnings: low downloads; no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 3.2.6 |
| Published | 2023-11-07 |
| First published | 2020-11-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 5.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51449 |
| Maintainers | types |

## Links

- npm: https://www.npmjs.com/package/@types/node-mongodb-fixtures
- Repository: https://github.com/DefinitelyTyped/DefinitelyTyped
- Homepage: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node-mongodb-fixtures
- npm.io page: https://npm.io/package/@types/node-mongodb-fixtures

## Dependencies (2)

- [mongodb](https://npm.io/package/mongodb.md) ^4.5.0
- [@types/node](https://npm.io/package/@types/node.md) *

## Recent versions

- 3.2.6 (latest) — 2023-11-07
- 3.2.3 (ts4.1) — 2022-04-24
- 3.2.2 (ts3.6) — 2021-07-26
- 3.2.0 (ts3.2) — 2020-11-17
- 3.2.5 — 2023-10-18
- 3.2.4 — 2023-09-23
- 3.2.1 — 2021-07-08

## README

# Installation
> `npm install --save @types/node-mongodb-fixtures`

# Summary
This package contains type definitions for node-mongodb-fixtures (https://github.com/cdimascio/node-mongodb-fixtures#readme).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node-mongodb-fixtures.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node-mongodb-fixtures/index.d.ts)
````ts
import { MongoClientOptions } from "mongodb";

/**
 * Setup and tear down test fixtures with MongoDB.
 *
 * Use custom scripts to create indexes and more!
 *
 * @see https://www.npmjs.com/package/node-mongodb-fixtures
 */
declare class Fixtures {
    constructor(options?: Fixtures.Options);

    /**
     * @param uri MongoDB connection string.
     *
     * @param options MongoDB connection options.
     *
     * @param dbName Identifies a database to switch to. Useful when the db in the connection string differs from the db you want to connect to.
     */
    connect(uri: string, options?: MongoClientOptions, dbName?: string): Promise<this>;

    load(): Promise<this>;

    unload(): Promise<this>;

    disconnect(): Promise<void>;
}

declare namespace Fixtures {
    interface Options {
        /**
         * Specifiy the fixtures directory or default to `./fixtures`.
         */
        dir?: string | undefined;

        /**
         * Filter the fixtures present in the directory with a regex pattern.
         */
        filter?: string | undefined;

        /**
         * Specify `true` to mute the log output or default to `false`.
         */
        mute?: boolean | undefined;
    }
}

export = Fixtures;

````

### Additional Details
 * Last updated: Tue, 07 Nov 2023 09:09:39 GMT
 * Dependencies: [@types/node](https://npmjs.com/package/@types/node), [mongodb](https://npmjs.com/package/mongodb)

# Credits
These definitions were written by [Chuah Chee Shian (shian15810)](https://github.com/shian15810).

---
_Source: https://npm.io/package/@types/node-mongodb-fixtures · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
