Skip to content

Hot reload: ship the dev ergonomics (follow-up to #132) #158

Description

@schloerke

examples/ui-tsx/09-hmr/ proves React Fast Refresh for the ui.tsx pattern with no backend change (a Vite dev server alongside Shiny; the dev stub swaps www/app.js). Two follow-ups remain:

  • Dev shinyreact bundle. Fast Refresh works today only because the example bundles its own dev React — window.shinyreact.React is a production build (js/vite.config.ts pins NODE_ENV=production) and can't drive react-refresh. A shinyreact.dev.js (React dev + refresh) would let the page share one dev React, but loading it needs a backend dev switch (the bundle is injected by the page dependency).
  • A shipped dev helper / CLI so authors don't hand-copy the vite.config stub plugin + shiny-bridge indirection.

Follow-up to #132.

Filed from the retired docs/todos.md.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions