{"repo":"molefrog/wouter","free":true,"listed":false,"github":"https://github.com/molefrog/wouter","clone":"git clone https://github.com/molefrog/wouter.git","description":"🥢 A minimalist-friendly ~2.2KB routing for React and Preact","language":"TypeScript","stars":7865,"topics":["react-hooks","router","microlibrary","zero-dependency","react","preact","typescript","react-router","hacktoberfest"],"license":"Unlicense","category":"ui-components","readme_excerpt":"wouter is a tiny router for modern React and Preact apps that relies on Hooks. A router you wanted so bad in your project! Features - Minimum dependencies, only 2.1 KB gzipped vs 18.7KB React Router. - Supports both React and Preact ! Read \"Preact support\" section for more details. - No top-level component, it is fully optional . - Mimics React Router's best practices by providing familiar Route , Link , Switch and Redirect components. - Has hook-based API for more granular control over routing (like animations): useLocation , useRoute and useRouter . developers :sparkling heart: wouter ... I love Wouter. It’s tiny, fully embraces hooks, and has an intuitive and barebones API. I can accomplish everything I could with react-router with Wouter, and it just feels more minimalist while not being inconvenient. Matt Miller , An exhaustive React ecosystem for 2020 Wouter provides a simple API that many developers and library authors appreciate. Some notable projects that use wouter: Ultra , React-three-fiber , Sunmao UI , Million and many more. Table of Contents - Getting Started - Browser Support - Wouter API - The list of methods available - Hooks API - useRoute : route matching and parameters - useLocation : working with the history - Additional navigation parameters - Customizing the location hook - useParams : extracting matched parameters - useSearch : query strings - useSearchParams : search parameters - useRouter : accessing the router object - Component API - - Route nestin","default_branch":null,"files":null,"tree":[],"storefront":"/r/molefrog","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/molefrog/wouter/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}