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

136 commits

Author SHA1 Message Date
Tanner Linsley
a0980b8015 docs: update 2024-01-11 10:09:39 -07:00
Manuel Schiller
048952c38d docs: fix typos 2024-01-10 23:10:57 +01:00
Manuel Schiller
a2a7d7e538
docs: update docs and examples to use route.fullPath instead of route.id as from (#928) 2024-01-10 14:52:04 -07:00
Alessandro
3bfa79d853
Update data-loading.md (#943)
Fix markdown typo
2024-01-07 03:45:14 +01:00
CHE1RON
b7899d0f49
chore: fix typo (#915) 2024-01-03 23:35:38 +01:00
Tanner Linsley
a60c718e76 docs: update ssr imports to @tanstack/react-router-server 2024-01-03 12:17:20 -07:00
CHE1RON
a4e23a8543
docs: fix typos (#906) 2024-01-03 12:54:56 +01:00
Marco Pasqualetti
d18672f638
docs: fix internal links (#874) 2023-12-25 22:29:06 -07:00
Cory House
87447fb205
Update data-loading.md (#875)
* Update data-loading.md

* Update data-loading.md
2023-12-25 17:19:51 -07:00
Cory House
11540a97b5
Update ssr.md (#876) 2023-12-25 17:19:13 -07:00
Cory House
b1d0f21765
Update route-masking.md (#878)
Grammar fixes
2023-12-25 17:17:04 -07:00
Cory House
a7bfe6fbc5
Update navigation-blocking.md (#879)
Grammar fixes
2023-12-25 17:16:22 -07:00
Cory House
cdef3904ee
Update code-splitting.md (#877) 2023-12-25 16:20:18 -07:00
Cory House
a29930264b
Update navigation.md (#872)
Grammar tweaks
2023-12-25 01:08:44 -07:00
Cory House
779996d70f
Update navigation.md (#871)
Grammar fix
2023-12-25 01:08:19 -07:00
Cory House
fc166d40c7
Update route-paths.md (#870)
Fix bad NotFoundRoute code example
2023-12-25 01:07:54 -07:00
Cory House
d38d3b6103
Update route-paths.md (#869)
Eliminate double negative
2023-12-25 01:07:23 -07:00
dan
2d90c16b17
Fix link to external data loading (#866) 2023-12-22 08:31:57 -07:00
Tanner Linsley
dd916436d2 fix: preloading without long-term caching 2023-12-19 14:14:13 -07:00
Tanner Linsley
ac29d55e94 fix: bring back shouldReload (but not its capability to track dependencies) 2023-12-19 00:08:12 -07:00
Tanner Linsley
00101df379 docs: do not recommend beforeLoad to build dynamic data 2023-12-18 17:39:49 -07:00
Tanner Linsley
3206f0481b fix: swr + remove shouldReload, activeOptions?.exact for search params 2023-12-18 17:28:12 -07:00
charlie
578cf99b79
Update deferred-data-loading.md (#856) 2023-12-17 10:58:15 -07:00
Tanner Linsley
8e7645ae24 feat: loaderDeps 2023-12-15 16:49:39 -07:00
Tanner Linsley
5ed8e42185 fix: preloading and potentially fix devtools context 2023-12-15 13:01:39 -07:00
Tanner Linsley
524b77179c fix: abolish component props in favor of top-level hooks, route methods or RouteApi methods 2023-12-13 23:35:52 -07:00
Tanner Linsley
aaebc47b0c fix: blockers now use async functions 2023-12-13 13:48:39 -07:00
Tanner Linsley
7ae13d9bfb fix: RouteApi class 2023-12-12 17:16:09 -07:00
Tanner Linsley
d288464b41 docs: pending and errors 2023-12-11 21:18:49 -07:00
Apola Kipso
99e725bdc7
Update authenticated-routes.md (#804)
Fixed typo
2023-12-09 23:33:16 -07:00
Hemanth Das
20f51bb52d
Update navigation.md (#784)
There is a spelling mistake `if if` is changed to `if`
2023-12-09 23:32:13 -07:00
Tanner Linsley
51a6d7e113 docs: update all docs 2023-12-09 00:16:13 -07:00
Tanner Linsley
8fab8b4175 feat: loader + ephemeral loaderData
Breaking Changes:

- `load` has been renamed back (I know...) to `loader`. Don't kill me. This again stays true to the nature of its functionality.
- `loader` can once again return data, but it is stored ephemerally on the route match and re-loaded on every navigation.
- If you choose to store data in `loaderData` from the `loader` function, you'll likely want to employ some level of caching to ensure you're only fetching data when necessary and resolving as early as possible if you have any meaningful cached data to display to the user. TanStack Query is a great tool to do this.
2023-11-29 01:16:52 -07:00
Tanner Linsley
722a3ce6b6 fix: refactor to full suspense + useTransition 2023-11-13 22:25:20 -07:00
Tanner Linsley
66ec994600 fix: Rename route and router meta back to route and router context
- Route meta and router meta have been renamed back to context. Bikeshed!
- The RouterContext class has been removed in favor of a new `rootRouteWithContext` factory function e.g. rootRouteWithContext<YourRouterContext>()(config)
2023-11-07 13:45:15 -07:00
Tanner Linsley
4a792144eb feat: Big refactor to React only
There are many breaking changes in this release:
- The Router class no longer has many of the methods it had.
- Most of these methods have been moved to the new routerContext, which is served via the useRouter() hook
- React state is being used for all state management, which should set the stage for better transition/suspense support
- Router Context and route context has been renamed to Router Meta and Route Meta
- Loaders are gone. You can still force a route to wait for an async function via `beforeLoad`, which is serial or `load` which is parallel.
- There's a lot of other changes, but I'm too tired to think straight.
2023-11-05 01:38:08 -06:00
Tanner Linsley
5fdf465ecf feat: loaderContext
Breaking Changes:
- `search` and `hash` are no longer directly available in route loaders
- The route `key` option has been removed

New:
- Added a new optional route option `loaderContext`. It's a function that receives `search` and `hash` and expects you to return any serializable data from them that you require in your loader. This stable-serialized value is used to uniquely identify route matches coming from this route configuration and acts as a dependency tracker for when loaders should rerun, etc.
2023-09-28 13:22:22 -06:00
Fugi
c414752513
fix: Fix force push removing commits (#728)
* docs: fixed variable name error (#715)

used the wrong example in customStringifier example

* Fix(router-cli): Fixes on Windows and Improvements  (#717)

* (fix) Fixed backslash on windows
(fix) Sanitized routePaths, import and interface keys
(enhanched) made the parent search recursive
(question) how layouts need to be generated?

* (feat) Added WIP example for file routing

* (fix) add debug json in ignored

* (fix) Added return type to 'hasParentRoute'
(fix) Removed example, moved to another branch

---------

Co-authored-by: Koja sig. Dennis <DKOJA@ceia-spa.com>

* fix: types for useNavigate and useMatchRoute (#723)

* document passing Link isActive to children (#725)

---------

Co-authored-by: Frank Tran <ftransd@gmail.com>
Co-authored-by: Denny09310 <50493437+Denny09310@users.noreply.github.com>
Co-authored-by: Koja sig. Dennis <DKOJA@ceia-spa.com>
Co-authored-by: Blake Gentry <bgentry@users.noreply.github.com>
2023-09-12 08:56:50 -06:00
Tanner Linsley
ae621c93ea feat: route masking 2023-09-11 10:07:10 -06:00
Frank Tran
0a57c073ca
docs: Add example for parseSearch and stringifySearch (#712) 2023-09-04 15:24:52 -06:00
Honza Gál
0c20da0092
docs: replace searchParams with search (#713) 2023-09-04 09:51:26 -06:00
Jesse Carter
1a05ac7587
docs: Update external-data-loading.md (#708)
* Update external-data-loading.md

* Update docs/guide/external-data-loading.md

---------

Co-authored-by: Tanner Linsley <tannerlinsley@gmail.com>
2023-09-03 10:27:54 -06:00
Tanner Linsley
12770b7150 fix: remove getContext, beforeLoad result decorates context 2023-09-01 16:42:39 -06:00
Tanner Linsley
11ea9663b7 fix: build 2023-09-01 13:51:53 -06:00
Tanner Linsley
778a9dc0b3 feat: resetScroll option 2023-08-27 22:19:00 -06:00
Tanner Linsley
e202adbcd7 docs/examples: fix deferred efficiency 2023-08-26 01:36:11 -06:00
Tanner Linsley
cf74bf16e6 Update ssr.md 2023-08-26 01:26:04 -06:00
Tanner Linsley
a121d4c449 docs: streaming, deferred, examples 2023-08-26 01:14:36 -06:00
Tanner Linsley
01f4760057 docs: scroll restoration, examples: renaming 2023-08-24 15:23:10 -06:00
Tanner Linsley
89a1a47d62 fix: error handling options and scroll restoration 2023-08-24 13:22:33 -06:00