# @types/giusto__ink-router

> TypeScript definitions for @giusto/ink-router

Latest version **2.4.8** (published 2023-12-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/giusto__ink-router
pnpm add @types/giusto__ink-router
yarn add @types/giusto__ink-router
bun add @types/giusto__ink-router
```

## 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.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 2.4.8 |
| Published | 2023-12-04 |
| First published | 2020-06-04 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 6.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51438 |
| Maintainers | types |

## Links

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

## Dependencies (2)

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

## Recent versions

- 2.4.8 (latest) — 2023-12-04
- 2.4.7 (ts4.5) — 2023-11-07
- 2.4.4 (ts3.8) — 2022-01-18
- 2.4.2 (ts3.6) — 2021-07-08
- 2.4.1 (ts3.2) — 2020-09-26
- 2.4.0 (ts3.0) — 2020-06-04
- 2.4.6 — 2023-10-18
- 2.4.5 — 2023-09-20
- 2.4.3 — 2021-11-25

## README

# Installation
> `npm install --save @types/giusto__ink-router`

# Summary
This package contains type definitions for @giusto/ink-router (https://github.com/lujiajing1126/ink-router).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/giusto__ink-router.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/giusto__ink-router/index.d.ts)
````ts
import { History, Location } from "history";
import { Component, ComponentType, JSX, ReactNode } from "react";

export interface RouterProps {
    children: NonNullable<ReactNode>;
    initialEntries?:
        | Array<
            (string | {
                pathname: string;
                search?: string | undefined;
                hash?: string | undefined;
                state?: any;
                key?: string | undefined;
            })
        >
        | undefined;
    initialIndex?: number | undefined;
    keyLength?: number | undefined;
    getUserConfirmation?: (() => void) | undefined;
}
export class Router extends Component<RouterProps> {}

export interface CommandLineRouterProps {
    children: NonNullable<ReactNode>;
    args?: string[] | undefined;
    options?: Record<string, any> | undefined;
    initialEntries?: string[] | undefined;
    initialIndex?: number | undefined;
}
export class CommandLineRouter extends Component<CommandLineRouterProps> {}

export interface RouteComponentProps<T extends Record<string, any> = {}> {
    match: {
        path: string;
        params: T;
    };
    location: Location<{}>;
    history: History<{}>;
}

export interface RouteProps {
    path: string;
    exact?: boolean | undefined;
    location?: {
        key?: string | undefined;
        pathname?: string | undefined;
    } | undefined;
    component: React.ComponentType<any>;
}
export class Route extends Component<RouteProps> {}

export interface SwitchProps {
    children?: React.ReactElement<RouteProps> | Array<React.ReactElement<RouteProps>> | undefined;
    notFound?: (() => any) | React.ComponentType<any> | undefined;
}
export class Switch extends Component<SwitchProps> {}

export function withRouter(component: ComponentType<any>): (props: any) => JSX.Element;

````

### Additional Details
 * Last updated: Mon, 04 Dec 2023 17:35:44 GMT
 * Dependencies: [@types/history](https://npmjs.com/package/@types/history), [@types/react](https://npmjs.com/package/@types/react)

# Credits
These definitions were written by [omjadas](https://github.com/omjadas).

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