# ps2census-nestjs

> PS2Census integration for NestJS

Latest version **1.0.0** (published 2021-08-01) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install ps2census-nestjs
pnpm add ps2census-nestjs
yarn add ps2census-nestjs
bun add ps2census-nestjs
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2021-08-01 |
| First published | 2020-09-26 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 118.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Microwavekonijn |
| Maintainers | microwavekonijn |
| Keywords | ps2census, nestjs, nest, typescript, planetside, census |

## Links

- npm: https://www.npmjs.com/package/ps2census-nestjs
- Repository: https://github.com/microwavekonijn/ps2census-nestjs
- Homepage: https://github.com/microwavekonijn/ps2census-nestjs#readme
- Issues: https://github.com/microwavekonijn/ps2census-nestjs/issues
- npm.io page: https://npm.io/package/ps2census-nestjs

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2021-08-01
- 0.2.1 — 2020-11-26
- 0.2.0 — 2020-11-26
- 0.1.2 — 2020-10-12
- 0.1.1 — 2020-10-12
- 0.1.0 — 2020-09-26

## README

# PS2Census NestJS

![CI](https://github.com/microwavekonijn/ps2census-nestjs/workflows/CI/badge.svg)
[![npm version](https://badge.fury.io/js/ps2census-nestjs.svg)](https://www.npmjs.com/package/ps2census-nestjs)
[![David DM Badge](https://david-dm.org/microwavekonijn/ps2census-nestjs.svg)](https://david-dm.org/microwavekonijn/ps2census-nestjs)

## About

Easy integration of the [PS2 Census library](https://github.com/microwavekonijn/ps2census) for NestJS.

## Installation

```
npm install ps2census ps2census-nestjs
```

## Getting started

```ts
import {CensusModule} from 'ps2census-nestjs';

@Module({
  imports:[
    CensusModule.forRoot({
      serviceID: 'your DBG service id',
      // Any other Client options from ps2census
    }),
    // or
    CensusModule.forRootAsync({
      useFactory: () => ({
        serviceID: 'your DBG service id',
        // Any other Client options from ps2census
      }),
    }),
  ],
  providers: [CensusGateway],
})
```

```ts
import { Injectable } from '@nestjs/common';
import {Death} from 'ps2census';
import {CensusClient} from 'ps2census-nestjs';

@Injectable() // Controller decorator can also be used
export class CensusGateway {
  constructor(
    client: CensusClient,
  ) {}

  @On({event: 'death'})
  deathHandler(death: Death): void {
    // Do something
  }
}
```

---
_Source: https://npm.io/package/ps2census-nestjs · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
