# @types/pluralize

> TypeScript definitions for pluralize

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

## Install

```sh
npm install @types/pluralize
pnpm add @types/pluralize
yarn add @types/pluralize
bun add @types/pluralize
```

## 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.0.33 |
| Published | 2023-11-07 |
| First published | 2016-05-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 5.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51445 |
| Maintainers | types |

## Links

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

## Recent versions

- 0.0.33 (latest) — 2023-11-07
- 0.0.30 (ts4.4) — 2023-07-06
- 0.0.29 (ts3.1) — 2018-07-14
- 0.0.32 — 2023-10-18
- 0.0.31 — 2023-09-24
- 0.0.28 — 2017-10-18
- 0.0.27 — 2016-09-19
- 0.0.26 — 2016-07-14
- 0.0.25-alpha — 2016-07-08
- 0.0.24-alpha — 2016-07-04
- 0.0.23-alpha — 2016-07-02
- 0.0.22-alpha — 2016-07-01
- 0.0.21-alpha — 2016-07-01
- 0.0.20-alpha — 2016-05-25
- 0.0.19-alpha — 2016-05-20
- … 2 more at https://npm.io/package/@types/pluralize/versions

## README

# Installation
> `npm install --save @types/pluralize`

# Summary
This package contains type definitions for pluralize (https://www.npmjs.com/package/pluralize).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/pluralize.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/pluralize/index.d.ts)
````ts
/**
 * Pluralize or singularize a word based on the passed in count.
 *
 * @param word
 * @param count
 * @param inclusive
 */
declare function pluralize(word: string, count?: number, inclusive?: boolean): string;

declare namespace pluralize {
    /**
     * Pluralize a word based.
     *
     * @param word
     */
    function plural(word: string): string;

    /**
     * Singularize a word based.
     *
     * @param word
     */
    function singular(word: string): string;

    /**
     * Add a pluralization rule to the collection.
     *
     * @param rule
     * @param replacement
     */
    function addPluralRule(rule: string | RegExp, replacement: string): void;

    /**
     * Add a singularization rule to the collection.
     *
     * @param rule
     * @param replacement
     */
    function addSingularRule(rule: string | RegExp, replacement: string): void;

    /**
     * Add an irregular word definition.
     *
     * @param single
     * @param plural
     */
    function addIrregularRule(single: string, plural: string): void;

    /**
     * Add an uncountable word rule.
     *
     * @param word
     */
    function addUncountableRule(word: string | RegExp): void;

    /**
     * Test if provided word is plural.
     *
     * @param word
     */
    function isPlural(word: string): boolean;

    /**
     * Test if provided word is singular.
     *
     * @param word
     */
    function isSingular(word: string): boolean;
}

export = pluralize;
export as namespace pluralize;

````

### Additional Details
 * Last updated: Tue, 07 Nov 2023 09:09:39 GMT
 * Dependencies: none

# Credits
These definitions were written by [Syu Kato](https://github.com/ukyo), and [Karol Majewski](https://github.com/karol-majewski).

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