# @types/react-router-hash-link

> TypeScript definitions for react-router-hash-link

Latest version **2.4.10** (published 2026-09-01) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/react-router-hash-link
pnpm add @types/react-router-hash-link
yarn add @types/react-router-hash-link
bun add @types/react-router-hash-link
```

## Health

**Score 70/100 (B)** — status: active.

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

Warnings: low downloads; no esm support.

## Facts

| | |
|---|---|
| Version | 2.4.10 |
| Published | 2026-09-01 |
| First published | 2018-08-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 4.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51441 |
| Maintainers | types |

## Links

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

## Dependencies (3)

- [@types/react](https://npm.io/package/@types/react.md) *
- [@types/history](https://npm.io/package/@types/history.md) ^4.7.11
- [@types/react-router-dom](https://npm.io/package/@types/react-router-dom.md) ^5.3.0

## Recent versions

- 2.4.10 (latest) — 2026-09-01
- 2.4.9 (ts4.5) — 2023-11-07
- 2.4.6 (ts4.3) — 2023-04-05
- 2.4.5 (ts4.2) — 2022-01-18
- 1.2.1 (ts3.9) — 2019-02-13
- 2.4.8 — 2023-10-18
- 2.4.7 — 2023-09-27
- 2.4.4 — 2021-11-05
- 2.4.3 — 2021-11-05
- 2.4.2 — 2021-09-14
- 2.4.1 — 2021-07-07
- 2.4.0 — 2021-05-18
- 2.0.0 — 2021-05-06
- 1.2.0 — 2018-08-15

## README

# Installation
> `npm install --save @types/react-router-hash-link`

# Summary
This package contains type definitions for react-router-hash-link (https://github.com/rafgraph/react-router-hash-link).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-router-hash-link.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-router-hash-link/index.d.ts)
````ts
import * as React from "react";
import { LinkProps, NavLinkProps } from "react-router-dom";

export interface HashLinkProps extends LinkProps {
    elementId?: string | undefined;
    smooth?: boolean | undefined;
    scroll?: ((element: HTMLElement) => void) | undefined;
    timeout?: number | undefined;
}

export interface NavHashLinkProps extends NavLinkProps, Omit<HashLinkProps, "className" | "style"> {}

export const HashLink: React.ForwardRefExoticComponent<HashLinkProps & React.RefAttributes<HTMLAnchorElement>>;

export const NavHashLink: React.ForwardRefExoticComponent<NavHashLinkProps & React.RefAttributes<HTMLAnchorElement>>;

export function genericHashLink<P>(Component: React.FunctionComponent<P>): React.FunctionComponent<P>;

````

### Additional Details
 * Last updated: Tue, 01 Sep 2026 19:04:12 GMT
 * Dependencies: [@types/history](https://npmjs.com/package/@types/history), [@types/react](https://npmjs.com/package/@types/react), [@types/react-router-dom](https://npmjs.com/package/@types/react-router-dom)

# Credits
These definitions were written by [Sam Baeck](https://github.com/zoompie), and [Eli Robinson](https://github.com/EliRobinson).

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