# temp-file

> ```typescript export function getTempName(prefix?: string | null | undefined): string;

Latest version **3.4.0** (published 2021-05-11) · MIT license · 0 weekly downloads

## Install

```sh
npm install temp-file
pnpm add temp-file
yarn add temp-file
bun add temp-file
```

## Health

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

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 3.4.0 |
| Published | 2021-05-11 |
| First published | 2017-08-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 17.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Vladimir Krivosheev |
| Maintainers | develar |

## Links

- npm: https://www.npmjs.com/package/temp-file
- Repository: https://github.com/develar/temp-file
- Issues: https://github.com/develar/temp-file/issues
- npm.io page: https://npm.io/package/temp-file

## Dependencies (2)

- [fs-extra](https://npm.io/package/fs-extra.md) ^10.0.0
- [async-exit-hook](https://npm.io/package/async-exit-hook.md) ^2.0.1

## Recent versions

- 3.4.0 (latest) — 2021-05-11
- 3.3.7 — 2020-03-03
- 3.3.6 — 2019-11-27
- 3.3.4 — 2019-07-08
- 3.3.3 — 2019-06-11
- 3.3.2 — 2018-11-16
- 3.3.1 — 2018-11-16
- 3.3.0 — 2018-11-16
- 3.2.0 — 2018-11-07
- 3.1.3 — 2018-06-27
- 3.1.2 — 2018-05-02
- 3.1.1 — 2018-01-13
- 3.1.0 — 2018-01-04
- 3.0.1 — 2018-01-04
- 3.0.0 — 2017-11-24
- … 11 more at https://npm.io/package/temp-file/versions

## README

## temp-file

```typescript
export function getTempName(prefix?: string | null | undefined): string;

export class TmpDir {
    getTempDir(suffix?: string): Promise<string>;
    
    createTempDir(suffix?: string): Promise<string>;
    
    getTempFile(suffix: string, isDir?: boolean, disposer?: ((file: string) => Promise<void>) | null): Promise<string>;
    
    cleanupSync(): void;
    
    cleanup(): Promise<any>;
}
```

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