Wouter is a minimalist client-side routing library for React and Preact. It uses a hook-based system to map URL paths to components, managing navigation and URL state without requiring a mandatory provider.
The library is designed for cross-ecosystem compatibility between React and Preact and supports server-side rendering by accepting initial paths and search strings during markup generation. It includes a URL parameter manager for extracting dynamic path segments and query strings from the browser address bar.
Capabilities include hierarchical nested routing, programmatic navigation management, and the ability to configure global base paths. It provides utilities for route pattern matching, automatic redirection, and navigation interception. For automated testing, the library includes a memory-based routing simulation to mock URL states.