# memoizefn-decorator-ts

> Ts decorator memoization that caches the result of the different arguments.

Latest version **1.2.6** (published 2021-04-05) · ISC license · 0 weekly downloads

## Install

```sh
npm install memoizefn-decorator-ts
pnpm add memoizefn-decorator-ts
yarn add memoizefn-decorator-ts
bun add memoizefn-decorator-ts
```

## 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.2.6 |
| Published | 2021-04-05 |
| First published | 2021-04-05 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 7.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Junior Denir |
| Maintainers | denirjr |
| Keywords | memoize, ts, angular, decorator, cache |

## Links

- npm: https://www.npmjs.com/package/memoizefn-decorator-ts
- npm.io page: https://npm.io/package/memoizefn-decorator-ts

## Alternatives

- [memory-cache](https://npm.io/package/memory-cache.md) — 795.0K weekly downloads
- [@httptoolkit/proxy-agent](https://npm.io/package/@httptoolkit/proxy-agent.md) — 11.2K weekly downloads
- [express-cache-controller](https://npm.io/package/express-cache-controller.md) — 5.3K weekly downloads
- [http-cache-middleware](https://npm.io/package/http-cache-middleware.md) — 4.5K weekly downloads
- [cache2](https://npm.io/package/cache2.md) — 1.5K weekly downloads

## Recent versions

- 1.2.6 (latest) — 2021-04-05
- 1.2.5 — 2021-04-05
- 1.2.4 — 2021-04-05
- 1.2.3 — 2021-04-05
- 1.2.2 — 2021-04-05
- 1.2.1 — 2021-04-05
- 1.2.0 — 2021-04-05
- 1.1.0 — 2021-04-05
- 1.0.1 — 2021-04-05
- 1.0.0 — 2021-04-05

## README

# Decorator_memoizeFn
Ts decorator memoization that caches the result of the different arguments.

Example:
```
import { Memoize } from "memoizefn-decorator-ts";

export class App {
  constructor() {
    console.log(this.some(3)); // calculated
    console.log(this.some(3)); // cached
    console.log(this.some(4)); // calculated
    console.log(this.some(4)); // cached
  }

  @Memoize()
  private some(n: number): number {
    return n + n;
  }
}

new App();

```

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