Skip to content

Types, types, types... and Preact-only package!

Compare
Choose a tag to compare
@molefrog molefrog released this 12 Aug 15:56

Improvements:

  • TypeScript types are now bundled with the library, including types for React and wouter/preact! Types are properly tested and can be maintained in the same repo. Thanks to @Ty3uK @StrayFromThePath and @polRk
  • Wouter now comes with a standalone package with Preact-only version: npm install wouter-preact. This makes it possible to use proper peerDependecies, and stop relying on React in your project #48 #49 cc/ @cedeber
  • 2nd argument of useLocation is now properly cached #74 #69 cc/ @neves
  • Links do not fire navigation when click using modifier keys like ctrl or ⌘ #68 thanks @marvinhagemeister
  • setLocation now supports a 2nd argument which allows to perform replaceState navigation (@Ty3uK via #52):
setLocation('/about', true); // calls replaceState instead of pushState