0.0.3 • Published 2 years ago

jacinto-router v0.0.3

Weekly downloads
-
License
-
Repository
-
Last release
2 years ago

Basic Router for React

Basic router for your React applications

Installation

npm i jacinto-router

Getting Started

  1. Import the Router component from the jacinto-router package:
import { Router } from 'jacinto-router'
  1. Wrap your application with the Router component
import { Router } from 'jacinto-router'
import Home from './Home'
import Contact from './Contact'

function App() {
  return (
    <Router>
      <Route path="/" component={Home} />
      <Route path="/contact" component={Contact} />
    </Router>
  );
}

export default App;
  1. Use the Link component to navigate through your application
import { Link } from 'jacinto-router';

<Link to='/'>Go to Home</Link>

Link also has target prop so you can change it when u need it

import { Link } from 'jacinto-router';

<Link to='/' target='_blank'>Go to Home</Link>

And thats it you can use it!

0.0.3

2 years ago

0.0.2

2 years ago