gzly-history-router
TypeScript icon, indicating that this package has built-in type declarations

0.2.1 • Public • Published

Grizzly's History Router

Build Status

Install

npm install --save gzly-history-router

import * as Gzly from 'gzly-history-router';

import DetailModule from './App/Controller/DetailModule';
import IndexModule from './App/Controller/IndexModule';

let modules = {
    'detail': { 
        instance: new DetailModule(), 
        children: {} 
    },
    'index': { 
        instance: new IndexModule(), 
        children: {} 
    },
};

let options = {
    duration: 500,
    useHashbang: true,
    rootElement: <HTMLElement>document.querySelector('body > main')
}

let router = new Gzly.Router(modules, options);
router.render();

Build it

npm run start - will trigger the watch job

npm run build - will trigger the build job

npm run test - will trigger -wait for it- the test job :)

The emoji guide for commit messages https://gitmoji.carloscuesta.me/

Dependencies (0)

    Dev Dependencies (9)

    Package Sidebar

    Install

    npm i gzly-history-router

    Weekly Downloads

    1

    Version

    0.2.1

    License

    MIT

    Unpacked Size

    60.4 kB

    Total Files

    30

    Last publish

    Collaborators

    • grizzly.web