Martin Trapp
@martr.app
450 followers 140 following 310 posts
Maintainer at @astro.build 🚀 Maker of 👜 Bags of Tricks ✨for view transitions @vtbag.dev
Posts Media Videos Starter Packs
Pinned
martr.app
Been lucky to benefit a lot from open source in my career. Since mid-2023, I've been giving back! As an Astro maintainer, I’ve focused on the client-side router, and I’m always ready to help with view transitions on Astro's Discord.
martr.app
Initially, I was like a kid in a candy store, selecting everything I wanted.
Later, I narrowed the list down to 19.

My guiding questions were:
– Is it an annoying incompatibility?
– Can I work around it?
– Would I be upset if X was left out because the time went into Y instead?
Reposted by Martin Trapp
kevinpowell.co
Do you have any smaller/under-the-radar CSS sites/people that you follow?

Looking for blogs, YouTube channels, or anyone who just shares cool CSS stuff.

Reply if you know any, and look at the replies for new people/sites to follow 😊
martr.app
Wow, hard to believe this was made over 2 years ago! Just tweak some CSS properties and let the browser figure out the transition. Why don’t we see animations like this on more websites by now?
martr.app
I started to add .catch(e => console.log(e)) to the view transition promises, at least for the updateCallbackDone (won't show anything in your case) and ready promises (would have printed "TimeoutError: Transition was aborted because of timeout in DOM update").

vtbag.dev/tips/view-tr...
View Transitions: What Could Possibly Go Wrong?
Most of the time, View Transitions just work. This page is for the exceptions: the quirks, the caveats, the things that quietly cancel your animations. Learn how to detect them and bring transitions b...
vtbag.dev
Reposted by Martin Trapp
martr.app
For everyone who cannot wait until native cross-document view transitions arrive: Your Astrojs sites with <ClientRouter> will already support view transitions for same-origin navigation in Firefox 144!
martr.app
For everyone who cannot wait until native cross-document view transitions arrive: Your Astrojs sites with <ClientRouter> will already support view transitions for same-origin navigation in Firefox 144!
martr.app
My start with view transitions was Astro‘s client router, which adds cross-document view transitions using only the level 1 API.

And as its swap function requires the entire new DOM, pre-rendering is the best approach.

Fun fact: i built that portal because i misunderstood a user‘s requirement 🥳
martr.app
Ah, that is interesting! Hadn‘t seen that before!
martr.app
I didn’t really keep up with it that enthusiastically back then. The render blocking might still causes noticeable stuttering.
martr.app
Haha, that was easy, I read a good explainer ;-)

vtbag.dev/basics/api/#...
nomster.bsky.social
Yes, you got it right!
martr.app
Congratulations Adam on your new role! Wishing you great success and an exciting journey ahead!
martr.app
"...and I'm somewhat involved in the design of this feature..."

That line had me grinning. I love how casually you put it.
Thanks, that really made my day!
martr.app
I spend some time wandering the depths of view transitions, but I guess I could find my way back to the surface with patterns that work in real projects. I would be glad to help out, sounds like fun to team up with you on this.
martr.app
Hi @samwho.dev, thank you very much, I really appreciate you sharing it! I am glad you found it useful, and even more glad if you have stumbling blocks to add ;-)
martr.app
Don’t trink and vibe!

That might turn out to be very useful one day if I ever want to vibe-code half drunk. Please take note: botl.new redirects to bolt.new ;-)
martr.app
Have fun! You have to dig a bit through the linked posts and the codepen. They also have pointers to vtbag.dev where the approach is covered in more detail.
martr.app
Thanks for the screenshot, Lou, really appreciate it!
martr.app
Thank you for the confirmation, Nathan.
Lack of hardware on my side ;(
martr.app
Hey friends out there with access to Safari's latest Technology Preview: Does vtbag.dev/basics/test-... light up the indicators for the active view transition property and Navigation API in your browser?
martr.app
Interesting question from Kevin Powell: having several view transition actions on the same page, is it possible to run them independently?
kevinpowell.co
So I made a quick demo and a video cause I can explain it better there :D

Video is too big for bksy though...

video explain: youtu.be/h71tY66w7f8
first example: codepen.io/kevinpowell/...
second example: codepen.io/kevinpowell/...
Reposted by Martin Trapp
vtbag.dev
We all are craving ;-)
vtbag.dev
Yep, L1 is a good start. There are ways to extend that into cross-document view transitions, e.g. with Astro. Safari quickly followed up with L2. @firefox.com might prioritize other goals like the remaining interop 2025 features.

But they know the whole community is craving MPA view transitions!
martr.app
Hi Barry, thanks for letting me know!
2025 is of course even better.

I have not heard much about progress, but there are still a few months left for improvement. ;-)