You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import * as React from "react";
import * as ReactDOM from "react-dom/client";
import "./index.css";
import App from "./App";
console.log("Hello world!");
ReactDOM.createRoot(document.getElementById("root")!).render(
<React.StrictMode>
<App />
</React.StrictMode>
);
Expected Behavior
The app shouldn't do full reload on route change. The console.log("Hello world!"); in main.tsx should be ran only once, like when using useRoute to create routes or elements.
Actual Behavior
Full app reload running console.log("Hello world!"); every route change. Is this the default behavior? If so, what's the rationale behind it?
The text was updated successfully, but these errors were encountered:
What version of React Router are you using?
6.27.0
Steps to Reproduce
App.tsx
main.tsx
Expected Behavior
The app shouldn't do full reload on route change. The
console.log("Hello world!");
in main.tsx should be ran only once, like when using useRoute to create routes or elements.Actual Behavior
Full app reload running
console.log("Hello world!");
every route change. Is this the default behavior? If so, what's the rationale behind it?The text was updated successfully, but these errors were encountered: