正在加载视频...

视频加载失败

I've been experimenting with block-based mega menus powered by a single custom block and the Interactivity API. Still a bit rough under the hood, but a successful proof-of-concept.

10,453 次观看 • 2 年前 •via X (Twitter)

10 条评论

Nick Diego 的头像
Nick Diego2 年前

I am in the middle of writing a detailed tutorial for the WordPress Developer Blog, but wanted to share a quick overview here:

Nick Diego 的头像
Nick Diego2 年前

The link is in the article, but the code for this block is available here:

Seth Rubenstein 的头像
Seth Rubenstein2 年前

You beat me to it Nick! I was just going to get started on an interactivity api driven mega menu block next week.

Nick Diego 的头像
Nick Diego2 年前

Please do, would love to compare and contrast approaches!

Mike McAlister 🛹 的头像
Mike McAlister 🛹2 年前

Super cool, Nick! I’ve played with a few POCs for this but have also been waiting for some changes in 6.5. It would be cool if you could launch that contextual pattern modal so users can visually choose which mega menu to apply (though I do t think it’s extensible like that).

Nick Diego 的头像
Nick Diego2 年前

Yeah, there is definitely some UX/UI work to do on the block in the Editor, especially if you were to make this functionality available to users who are not that familiar with the Site Editor.

Darren Pinder 的头像
Darren Pinder2 年前

Nick this is great! We keep coming up with use cases for megamenus but have been unable to build with FSE yet. Really looking forward to seeing the detailed write-up! cc @michaelbragg

De Belser Arne 的头像
De Belser Arne2 年前

This is absolutely fascinating! I attempted to replicate this functionality before, but encountered challenges. It seems like it's time to delve back into it once more.

Jonathan Desrosiers 的头像
Jonathan Desrosiers2 年前

This stuff gets me fired up! Great work as always Nick!

Nick Diego 的头像
Nick Diego2 年前

There are a lot of new toys coming in 6.5 💪

相关视频