Packages

react-router

8.5.1 · 27 Oct 2026MIT80.5M / weekRepositorynpmAtom feed

Your version

7.6.3

27 Jun 2025Where it was published

7.18.6 is the newest release of 7.x.

In short

1 fixed

Security

13 advisories affect 7.6.3; 7.18.0 fixes them

8 more

Release note

The section about react-router of a note shared by several packages.

Patch Changes

  • Do not serialize types for useRouteLoaderData<typeof clientLoader>

    For types to distinguish a clientLoader from a serverLoader, you MUST annotate clientLoader args:

    //                                   👇 annotation required to skip serializing types
    export function clientLoader({}: Route.ClientLoaderArgs) {
      return { fn: () => "earth" };
    }
    
    function SomeComponent() {
      const data = useRouteLoaderData<typeof clientLoader>("routes/this-route");
      const planet = data?.fn() ?? "world";
      return <h1>Hello, {planet}!</h1>;
    }

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.