Created
August 7, 2019 09:51
-
-
Save ovpv/508653eba9449d1e2400ac0080022542 to your computer and use it in GitHub Desktop.
adding react router dom browser router to client side
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import { hydrate } from "react-dom"; | |
import App from "./app"; | |
import { BrowserRouter as Router } from "react-router-dom"; | |
hydrate( | |
<Router> | |
<App /> | |
</Router>, | |
document.getElementById("app") | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment