Skip to content

useRouteLoaderData and unstable_useRoute undefined when using RSC plugin #14911

@evaogbe

Description

@evaogbe

Reproduction

https://stackblitz.com/edit/github-rwjirmyc?file=app%2Froutes%2Fhome.tsx

System Info

System:
    OS: macOS 26.3.1
    CPU: (8) x64 Intel(R) Core(TM) i5-1038NG7 CPU @ 2.00GHz
    Memory: 30.45 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 24.11.1 - /usr/local/bin/node
    Yarn: 1.22.22 - /Users/eoogbe/.yarn/bin/yarn
    npm: 11.6.2 - /usr/local/bin/npm
    pnpm: 10.32.1 - /usr/local/bin/pnpm
    Watchman: 2025.05.26.00 - /usr/local/bin/watchman
  Browsers:
    Chrome: 146.0.7680.81
    Firefox: 148.0.2
    Safari: 26.3.1
  npmPackages:
    @react-router/dev: 7.13.2 => 7.13.2 
    @react-router/node: 7.13.2 => 7.13.2 
    @react-router/serve: 7.13.2 => 7.13.2 
    react-router: 7.13.2 => 7.13.2 
    vite: ^7.1.7 => 7.3.1

Used Package Manager

npm

Expected Behavior

All ways of accessing the loader data from a component returns the loader data. This is the case when using the normal plugin without RSCs.

Actual Behavior

useRouteLoaderData and unstable_useRoute are undefined

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions