DEV Community

Discussion on: Creating Tabs component in Vue 3

 
zafaralam profile image
Zafar Alam

Hi @karnie6 I've updated the tabs component and it should now render the tabs dynamically. Look at the examples 7 & 8 in the App.vue file for how you can use it.

Hope this helps and thanks again for providing an example.

Thread Thread
 
karnie6 profile image
Karthik Senthil

hey @zafaralam - AMAZING! Looks like it works, thanks so much for the quick fix!

FYI, I'd love to share what I'm building with you - if you're interested, wanna email me at karthik dot senthil at gmail ? Thanks!

Thread Thread
 
karnie6 profile image
Karthik Senthil

@zafaralam - one other question. If i wanted to refresh the tab content on tab click, what's the best way to do that? Does have to listen to the 'tabChanged' event and do a force refresh? If so, what way would you recommend implementing that?

Thread Thread
 
zafaralam profile image
Zafar Alam

I would hook into the tabChanged event and then write my logic in the component that has the tabs in it.

This way you will be able to better control the refresh behaviour and it will be decoupled from the tabs component.

Also my email is syed.alam@live.com.au or you can reach out to me on twitter @zafalam.

Thread Thread
 
karnie6 profile image
Karthik Senthil

Got it to work - and just followed you on Twitter!