freezer-router5
Router5 plugin for using freezer-js along with router5. The plugin will sync routing state in a freezer instance.
Loosely based on redux-router5 plugin.
example
;;; const router = ;const fridge = {};const plugin = ; // second argument defaults to 'router'router; // from now on, router state is kept fresh in the fridgerouterstart { router;};
To get something closer to redux-router5
(i.e. dispatching actions to control
the router), there is an augmented version of the plugin that will do that:
;;;; const router = ;const fridge = {};const plugin = ;router; // the router is controllable through triggered actionsfridge;fridge;fridge;
install
npm i freezer-js-router5 -S
Note that router5 and freezer-js are peer dependencies. Depending on you package manager, you might have to provide them yourself.
extra notes
The bundling scripts are from https://github.com/gilbox/react-derive.