# @types/jpeg-autorotate

> TypeScript definitions for jpeg-autorotate

Latest version **5.0.4** (published 2025-09-29) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/jpeg-autorotate
pnpm add @types/jpeg-autorotate
yarn add @types/jpeg-autorotate
bun add @types/jpeg-autorotate
```

## Health

**Score 55/100 (C)** — status: stable.

Positive: has types; no vulnerabilities; high maintenance score; popular repo; extremely popular.

Warnings: low downloads; no esm support.

Negative: stale.

## Facts

| | |
|---|---|
| Version | 5.0.4 |
| Published | 2025-09-29 |
| First published | 2018-12-19 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 4.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51441 |
| Maintainers | types |

## Links

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

## Dependencies (1)

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

## Recent versions

- 5.0.4 (latest) — 2025-09-29
- 5.0.3 (ts4.5) — 2023-11-07
- 5.0.1 (ts3.6) — 2021-07-08
- 5.0.0 (ts2.4) — 2019-04-15
- 5.0.2 — 2023-10-18
- 4.0.0 — 2018-12-19

## README

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

export enum errors {
    read_file = "read_file",
    read_exif = "read_exif",
    no_orientation = "no_orientation",
    unknown_orientation = "unknown_orientation",
    correct_orientation = "correct_orientation",
    rotate_file = "rotate_file",
}

export interface CustomError extends Error {
    code: errors;
}

export interface RotateOptions {
    quality?: number | undefined;
}

export interface RotateDimensions {
    height: number;
    width: number;
}

export function rotate(
    path_or_buffer: string | Buffer,
    options: RotateOptions,
): Promise<{
    buffer: Buffer;
    orientation: number;
    dimensions: RotateDimensions;
    quality: number;
}>;

export function rotate(
    path_or_buffer: string | Buffer,
    options: RotateOptions,
    module_callback?: (
        error: CustomError | null,
        buffer: Buffer,
        orientation: number | null,
        dimensions: RotateDimensions | null,
        quality: number | null,
    ) => void,
): void;

````

### Additional Details
 * Last updated: Mon, 29 Sep 2025 18:02:29 GMT
 * Dependencies: [@types/node](https://npmjs.com/package/@types/node)

# Credits
These definitions were written by .

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