0
Fork 0
mirror of https://github.com/TanStack/router.git synced 2026-11-16 19:38:07 +00:00
Commit graph

6,689 commits

Author SHA1 Message Date
Sean Cassiere
b109ce5ae7
test(react-router): correct usage of act and waitFor (#1986)
* test(react-router): reduce `act` and `waitFor`

* test: remove unncessary waitFor

* test(react-router): remove waitFor and act

* test(react-router): act and waitFor

* loaders

* link.test.tsx
2024-07-19 10:42:40 +12:00
Sean Cassiere
7ad94a5021
test(react-router): correct use act in routeContext.test.tsx (#1985)
* test(react-router): correct use `act` in `routeContext.test.tsx`

* test(react-router): another removal

* test(react-router): reduce `act` on `fireEvent`
2024-07-19 09:48:09 +12:00
Sean Cassiere
99a0820853
test(react-router): active state for <Link> is correct when a search parameter value is set to undefined (#1969)
* fix(react-router): add util to remove undefined values in objects

* test(react-router): add test cases to make sure the util works

* test(react-router): import sorting

* test(react-router): check the search params with the value undefined

* fix(react-router): fix the active/inactive states being wrong when a search value is set to `undefined`

* chore(react-router): remove unused `useMatch` import in `link.tsx`

* test(react-router): better naming of the index exact link selector

* refactor(react-router): `deepEqual` to use `deepRemoveUndefinedFromObject` under the hood

* fix(react-router): handling null in the `deepRemoveUndefinedFromObject` function

* test(react-router): expanding the test-suite for `deepRemoveUndefinedFromObject`

* fix(react-router): remove that typeof check I added

* test(react-router): amend the tests from #1975

* refactor(react-router): remove `deepRemoveUndefinedFromObject`
2024-07-19 09:05:06 +12:00
Tanner Linsley
2212a540a4 release: v1.45.6 v1.45.6 2024-07-18 20:52:26 +00:00
Manuel Schiller
522bc12a3f
fix(react-router): deepEqual correctly handles undefined properties (#1984) 2024-07-19 08:48:59 +12:00
Tanner Linsley
adea0c2e2b release: v1.45.5 v1.45.5 2024-07-18 18:52:43 +00:00
Christopher Horobin
99f735251f
fix(react-router): use current matches for fromMatches and only build new matches when location overridden (#1968)
* fix: use current matches for `fromMatches` and only build new matches when location overridden

* fix: use current matches for `fromMatches` and only build new matches when location overridden

* style(react-router): prettier on `router.ts`

---------

Co-authored-by: SeanCassiere <33615041+SeanCassiere@users.noreply.github.com>
2024-07-18 20:48:57 +02:00
Sean Cassiere
7452f23f22
test(react-router): reducing the React.act warnings during unit tests (#1975)
* test(react-router): loaders

* chore(react-router): act does not need to be awaited here

* test(react-router): createLazyRoute

* test(react-router): useMatch

* test(react-router): add a setupTests file

* test(react-router): router

* test(react-router): renable these tests 😅

* refactor(react-router): move to the waitFor flow

* refactor(react-router): link
2024-07-18 00:16:44 +12:00
Tanner Linsley
da9d52a9e7 release: v1.45.4 v1.45.4 2024-07-16 19:33:12 +00:00
Sean Cassiere
adcdb4cf43
style: prettier across the codebase (#1973) 2024-07-17 07:31:42 +12:00
Tanner Linsley
50aec3fe5b examples: fix trellaux example 2024-07-16 13:01:24 -06:00
Tanner Linsley
65fab472e7 fix: Clear pending timeouts on cancelMatch
Fixes an issue where rapid navigations could cause a pending timeout to fire for an outdated route match and erroneously trigger a pending state on the latest match version.
2024-07-16 12:55:13 -06:00
Tanner Linsley
9cdef82809 fix: useMatchRoute now subscribes to pending and location states
Fixes an issue where the pending option would get stuck and the component or hook parent component would never rerender since it wasn't listening to the pending state or location/resolvedLocation states.
2024-07-16 12:53:41 -06:00
Tanner Linsley
82ef303c9a release: v1.45.3 v1.45.3 2024-07-16 17:35:51 +00:00
Tanner Linsley
3003d986c6
fix(router): fixed a lot of context related issues (#1907) 2024-07-16 19:34:14 +02:00
Sean Cassiere
cd85ca1de1
chore: cleanup styles and eslint errors in the spa examples (#1971)
* style(examples): kitchen sink examples

* style(examples): more kitchen sink examples

* style(examples): basic examples

* style(examples): authenticated routes example

* style(examples): authentication routes example

* style(examples): scroll restoration

* style(examples): navigation blocking

* style(examples): defered data example

* style(examples): location masking example

* style(examples): quickstart examples
2024-07-17 02:28:39 +12:00
Tom Ballinger
020fb747e6
examples: use ensureQuery in start-basic-react-query (#1962) 2024-07-15 19:03:06 +02:00
Tanner Linsley
60091b30f7 release: v1.45.2 v1.45.2 2024-07-15 10:42:19 +00:00
Sean Cassiere
0b403aa84c
fix(react-router): URI path segments segments should match on equality regardless of their encoding state (#1964)
* test(react-router): reduce duplication in the encoding tests

* test(react-router): adding the tests

* test(react-router): get the tests to a place I can work with them

* fix(react-router): URI path segments segments should have the same equality regardless of their encoding status

* test(react-router): add tests using an emoji

* test(react-router): simplify the tests
2024-07-15 22:41:08 +12:00
renovate[bot]
080834aa86
chore(deps): update dependency rsbuild to ^0.7.10 (#1961)
* chore(deps): update dependency @rsbuild/core to ^0.7.10

* Update @rsbuild/plugin-react

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lachlan Collins <1667261+lachlancollins@users.noreply.github.com>
2024-07-15 14:24:53 +10:00
renovate[bot]
a590499e94
chore(deps): update all non-major dependencies (#1960)
* chore(deps): update all non-major dependencies

* Format

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lachlan Collins <1667261+lachlancollins@users.noreply.github.com>
2024-07-15 13:59:43 +10:00
renovate[bot]
781b9f194b
chore(deps): update dependency framer-motion to v11 (#1957)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-14 18:42:08 +10:00
renovate[bot]
54d2499e2a
chore(deps): update dependency tailwind-merge to v2 (#1956)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-14 18:20:41 +10:00
Tanner Linsley
fdeabdad83 release: v1.45.1 v1.45.1 2024-07-14 08:09:41 +00:00
Lachlan Collins
b50e9a500c
fix(router-devtools): remove date-fns (#1955) 2024-07-14 18:08:05 +10:00
Sean Cassiere
b1d86cc709
docs: add verbiage on the "router-context" guide about invalidating the router context for external state changes (#1954) 2024-07-13 23:30:29 +12:00
Tanner Linsley
c9911b9e76 release: v1.45.0 v1.45.0 2024-07-12 20:13:20 +00:00
Manuel Schiller
bacd6b7f22
feat: allow useMatch to not throw if match was not found (#1738)
in this case, `matchRoute` will return undefined
2024-07-12 22:09:43 +02:00
renovate[bot]
cc7730a4f9
chore(deps): update all non-major dependencies (#1952)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-13 04:27:24 +10:00
Tanner Linsley
e2154f4e38 release: v1.44.5 v1.44.5 2024-07-12 17:09:31 +00:00
Christopher Horobin
d6b8823542
fix: when children are added to the route tree, the inference of RouterContext is lost (#1946) 2024-07-12 19:06:25 +02:00
Tanner Linsley
79a7131dad release: v1.44.4 v1.44.4 2024-07-12 01:41:06 +00:00
Sean Cassiere
96bd23e377
fix(react-router): scroll-restoration not being persisted on initial load (#1948) 2024-07-12 13:39:27 +12:00
Tanner Linsley
05268ddea7 release: v1.44.3 v1.44.3 2024-07-11 23:26:26 +00:00
Sean Cassiere
63aa484180
fix(router-generator): throw an error when a route configuration is found for a grouping identifier (#1947)
* style(router-generator): stop the tests from screaming about ts-errors and eslint-errors

* test(router-generator): add tests to expect an error on failure

* fix(router-generator): do not allow route-groups to have route-configurations

* chore(router-generator): tsconfig to ignore the test snapshot content

* chore(router-generator): remove unused import
2024-07-12 11:24:51 +12:00
Casey Johnson
0b5bff5942
docs: update the list of parameters available in the loader in the "data loading" guide (#1945)
* fix: loader parameters in data loading documentation

* Update docs/framework/react/guide/data-loading.md

Co-authored-by: Sean Cassiere <33615041+SeanCassiere@users.noreply.github.com>

---------

Co-authored-by: Sean Cassiere <33615041+SeanCassiere@users.noreply.github.com>
2024-07-12 09:48:30 +12:00
Tanner Linsley
77116e45bf release: v1.44.2 v1.44.2 2024-07-11 04:51:20 +00:00
Lachlan Collins
7e1b51d8ce
ci: update @tanstack/config (#1942) 2024-07-11 14:49:22 +10:00
Lachlan Collins
a4aed48495
ci: enable npm provenance (#1941) 2024-07-11 14:21:38 +10:00
renovate[bot]
89de378cc9
chore(deps): update dependency redaxios to ^0.5.1 (#1938)
* chore(deps): update dependency redaxios to ^0.5.1

* Ignore use-sync-external-store

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lachlan Collins <1667261+lachlancollins@users.noreply.github.com>
2024-07-10 23:53:13 +10:00
renovate[bot]
bb68dec0d9
chore(deps): update dependency isbot to v5 (#1937)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-10 23:39:09 +10:00
renovate[bot]
8235d0f246
chore(deps): update dependency @testing-library/react to v16 (#1936)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-10 23:36:58 +10:00
Tanner Linsley
f1462f38bc release: v1.44.1 v1.44.1 2024-07-10 13:30:58 +00:00
Lachlan Collins
5c14d16237
fix(deps): update vinxi dependencies (#1935) 2024-07-10 23:29:02 +10:00
Lachlan Collins
1a158a2b00
chore(deps): remove unused dev dependencies (#1934) 2024-07-10 23:18:40 +10:00
renovate[bot]
a78e067a94
chore(deps): update all non-major dependencies (#1933)
* chore(deps): update all non-major dependencies

* Remove non-root packageManager fields

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lachlan Collins <1667261+lachlancollins@users.noreply.github.com>
2024-07-10 23:08:53 +10:00
renovate[bot]
117db17239
chore(deps): update dependency hono to v4 [security] (#1931)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-10 22:56:15 +10:00
Lachlan Collins
569379ad68
ci(renovate): add renovate config (#1930) 2024-07-10 22:48:00 +10:00
Sean Cassiere
9880bb8bb1
docs: use gfm alerts in the documentation (#1924)
* docs: gfm alerts on the deprecated apis

* docs: gfm alerts in the api reference

* docs: gfm alerts in framework/react

* docs: gfm alerts in framework/react/guide

* docs: more gfm alerts in the api reference

* docs: update to the decisions on dx doc
2024-07-10 11:46:21 +12:00
Tanner Linsley
e0ceb51b0c release: v1.44.0 v1.44.0 2024-07-09 20:27:14 +00:00