Negligible Participation Metric
    Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    boajs-routerpublic

    This package has been deprecated

    Author message:

    use boa-router

    boajs-router

    A routing library for bouzuya/b-o-a.

    Installation

    $ npm install boajs-router
    

    Usage

    import { init } from 'boajs-router';
    const routes = [
      { path: '/users' },
      { path: '/users/:id' }
    ];
    const router = init(routes);
    const matched = router('/users/123');
    // { route: { path: '/users/:id' }, params: { id: '123' } }
     
    const notMatched = router('/items');
    // null

    Badges

    Circle CI

    License

    MIT

    Author

    bouzuya <m@bouzuya.net> (http://bouzuya.net)

    Keywords

    none

    install

    npm i boajs-router

    Downloadsweekly downloads

    8

    version

    0.3.0

    license

    MIT

    repository

    githubgithub

    last publish

    collaborators

    • avatar