<HashRouter>

This is a <Router> that uses the hash portion of the URL (i.e. window.location.hash) to keep your UI in sync with the URL.

For instance, when you send www.mywebsite.com/#/person/john, the server gets www.mywebsite.com and client-side React handles '/person/john/'. The # part is used to prevent us from sending repeated GET requests. Server-side routing is thus independent from client-side routing, which is why <HashRouter> needs no special server configuration at all – useful on static hosts that can't be configured with a fallback route.


<HashRouter basename={optionalString}>
  <App />
</HashRouter>

The old "getUserConfirmation" and "hashType" ("slash" / "noslash" / "hashbang") attributes are gone – there's no built-in way to customize the hash format anymore.