Skip to content

keajs/kea-router

Repository files navigation

NPM Version minified minified + gzipped Backers on Open Collective Sponsors on Open Collective

kea-router

Router plugin for kea. Version 3 works with kea 3.0.0 and up.

Installation

Install the package:

yarn add kea-router

Add the plugin to the list when resetting the context:

import { routerPlugin } from 'kea-router'

resetContext({
  plugins: [routerPlugin]
})

You may add extra options with routerPlugin(options), see the source for more :)

Sample usage

Read the documentation