npm

npm’s 2019 JavaScript ecosystem survey analysis is now available!Get your copy here »

react-pretence-router

1.0.5 • Public • Published

react-pretence-router

This router is based on React-Redux and use state in Redux store to decide which component will be rendered. It look like a router but it isn't a real router like React-Router.

It is lightweight, simple to use and useful for small application or web browser extension development. Simple way for simple requirement (^_~).

I recommend you use Redux DevTools extension to know more about what happen and how data changed when you develop your app.

Example usage

import React from 'react';
import { Link } from 'react-pretence-router';

export const Menu = () => (
    <div>
        <Link to={'/'} name={'Home'} css={'menu'}/>
        <Link to={'/about'} name={'About'} css={'menu'}/>
        <Link to={'/contact'} name={'Contact'} css={'menu'}/>
    </div>
)

View on GitHub to know more how to use and other information.

install

npm i react-pretence-router

Downloadsweekly downloads

5

version

1.0.5

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability