React Router
createMemoryRouter
Create a data router with memory-based history.
Formal Syntax & Structure
react syntaxreact
createMemoryRouter(routes, options)Working Example
Example Snippetreact
createMemoryRouter(routes, {initialEntries:["/"]})Create a data router with memory-based history.
createMemoryRouter(routes, options)createMemoryRouter(routes, {initialEntries:["/"]})