Rezact / Rezact

A JavaScript Framework/Library (call it what you want) that blends the best of svelte, solid, react, and many others.

Home Page:https://rezact.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Pass {router} prop into page components

zachlankton opened this issue · comments

This will be a light refactor, but instead of passing routeParams and router_outlet as props, we should pass a single router prop that has everything:

{
  route: {path, param, data, meta}
  outlet,
  go: //method, Traverses history in a given direction.
  push: //metjod Navigates to a location. In the case of an HTML5 History implementation, this will call history.pushState to effectively change the URL,
  replace: //method, Same as push but performs a history.replaceState instead of history.pushState,
...etc...
}