hyperapp-router
hyperapp-router copied to clipboard
Declarative routing for Hyperapp V1 using the History API.
See this codepen: https://codepen.io/zaceno/pen/RxRjVZ It is a simple copy-paste of the first example in the README.md. Only I've changed ```js import { Link, Route, location } from "@hyperapp/router" ``` to...
The current routing approach lets you control which components render based on the curent `window.location`, but it does not take into account the need for other side effects when the...
Allow multiple routers to coexist by not wrapping the pushstate and replacestate functions multiple times and triggering the router listeners after creating it.
Please see this example: https://codepen.io/zaceno/pen/vRwERE?editors=0011 Each page ("A" and "B") has a plain `p` with no key as its top node. Notice when you navigate between "PageA" and "PageB" the...
Include Basepath
Add a simple check for `undefined` to the window and history objects to avoid errors when using `@hyperapp/router` on the server side in combination with `@hyperapp/render`. Assuming the `subscribe` method...
Getting error when going to `/edge` ``` import { Link, Route, Switch, location } from "@hyperapp/router"; import welcome from "./views/welcome"; import edge from "./views/edge"; const routes = (state, actions) =>...
On my local, I use http://localhost:8080/greetings, but deployed its https://production/some-path/greetings In my code, I want to write `` and have it work in both dev and production React-router has this:...