# @types/poker-evaluator

> TypeScript definitions for poker-evaluator

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

## Install

```sh
npm install @types/poker-evaluator
pnpm add @types/poker-evaluator
yarn add @types/poker-evaluator
bun add @types/poker-evaluator
```

## 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; pre 1.0.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 0.3.7 |
| Published | 2023-11-07 |
| First published | 2019-11-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 3.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51446 |
| Maintainers | types |

## Links

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

## Dependencies (1)

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

## Recent versions

- 0.3.7 (latest) — 2023-11-07
- 0.3.4 (ts3.8) — 2021-12-16
- 0.3.3 (ts3.0) — 2020-08-17
- 0.3.2 (ts2.8) — 2020-02-19
- 0.3.6 — 2023-10-18
- 0.3.5 — 2023-09-24
- 0.3.1 — 2020-02-18
- 0.3.0 — 2019-11-11

## README

# Installation
> `npm install --save @types/poker-evaluator`

# Summary
This package contains type definitions for poker-evaluator (https://github.com/chenosaurus/poker-evaluator).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/poker-evaluator.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/poker-evaluator/index.d.ts)
````ts
/// <reference types="node" />

export const HANDTYPES: HandName[];
export const CARDS: Deck;
export const ranks: Buffer;

export function evalHand(cards: string[] | number[]): EvaluatedHand;

export type HandName =
    | "invalid hand"
    | "high card"
    | "one pair"
    | "two pairs"
    | "three of a kind"
    | "straight"
    | "flush"
    | "full house"
    | "four of a kind"
    | "straight flush";

export interface Deck {
    [key: string]: number;
}

export interface EvaluatedHand {
    handType: number; // Index of HANDTYPES array
    handRank: number;
    value: number;
    handName: HandName;
}

````

### Additional Details
 * Last updated: Tue, 07 Nov 2023 09:09:39 GMT
 * Dependencies: [@types/node](https://npmjs.com/package/@types/node)

# Credits
These definitions were written by [Rory McGuinness](https://github.com/rorymcgit).

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