正在加载视频...

视频加载失败

How to show inline loading indicator when updating search params in Next.js (App Router)

61,834 次观看 • 1 年前 •via X (Twitter)

9 条评论

Dan Skiba 的头像
Dan Skiba1 年前

I prefer progress bar at the top of a page and for that reason I've created lil hooks demo:

Ollie Martynov 的头像
Ollie Martynov1 年前

Ah yes. The good old transitions api

Tomas Jansson 的头像
Tomas Jansson1 年前

An even more general approach would be to wrap link and add a (discrete) loading indicator for all navigations. Very nice though! It is so nice to see how you communicate simple examples!

marcog🧉 的头像
marcog🧉1 年前

useTransition is a native hook from react?

Coding With Mr.M 的头像
Coding With Mr.M1 年前

Nice , but just to add if we use @tan_stack then we no need to use that, we can just use the mutation.isLoading

Matt 的头像
Matt1 年前

Man this is gold I didn’t know u could do this 🤯

Kiran 的头像
Kiran1 年前

Nice, i'm using the same but with nuqs to update the search params.

elsie 的头像
elsie1 年前

hi Alex, how to display tailwind icon when we short the line of code ?

Umair Ali 的头像
Umair Ali1 年前

If we want the same on pages route?

相关视频