preact-router-hash

0.0.1 • Public • Published

preact-router

Usage Example

import Router from 'preact-router';
import { h, render } from 'preact';
/** @jsx h */
 
const Main = () => (
    <Router hashHistory={true}>
        <Home path="/" />
        <About path="/about" />
        <Search path="/search/:query" />
    </Router>
);
 
render(<Main />, document.body);

Everything the same as preact-router. Add hashHistory to Router to test ..

Readme

Keywords

Package Sidebar

Install

npm i preact-router-hash

Weekly Downloads

5

Version

0.0.1

License

MIT

Last publish

Collaborators

  • ug1989