Skip to content

Fix HMR #2695

@david-crespo

Description

@david-crespo

HMR doesn’t work at all. Totally my fault: #2545 exports components and loaders from the same file, which breaks HMR. Those route files are all the top level files and HMR is broken for any changes below them, so it’s broken for all changes. This is annoying because it takes a few seconds to see a change instead of like 50ms, and it refreshes the page, losing any client-side state.

That change was meant to prepare us for RR v7 in framework mode + SPA mode, but I’m not sure how feasible that is for us. So we need to determine whether we plan to move to that, and if not, switch all the route files back to sticking loader on PageComponent.loader.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions