- Bugfix: useQueryParams now properly updates when changing the QueryParams.
- Bugfix the type of the pathParams was incorrectly set to QueryParam in the urlBuilder. Now has its own generic called PathParam.
- Removed QueryParams as a model now expecting the user to provide them via generics instead.
- Changed package name to '42.nl/react-url'
- Added useQueryParams hook
- Converted project to TypeScript
This release contains breaking changes, to migrate do the following:
Use the urlBuilder
instead of the urlQueryBuilder
now. The
urlQueryBuilder
has been renamed to urlBuilder
, and the old
urlBuilder
is no longer exposed. So everything should work
as intended.
Changes:
-
Reduced the API surface of the library exposing one builder called:
urlBuilder
. It behaves the same asurlQueryBuilder
did. -
withQueryParams
now converts the query params from strings to a more concrete type based on the default query params.
- The first version of this library.