A Taste of using Vuetify in Go

Vuetify is a really mature Vue components library for Material Design. We have made the efforts to integrate most all of it as a go package. You can use it with ease just like any other go package.

Use container, toolbar, list, list item etc

This example is purely render, we didn't integrate any interaction (event func) to it.

Use menu, card, list, etc

This example uses the menu popup, card, list component. and some interactions of clicking buttons on the menu popup.

.VSlot("{ locals, form }").Init("{ myMenuShow: false }").FormInit(JSONString(fv)) used to initialize the variables of web.Scope. locals corresponds to the Init method and form corresponds to the FormInit method.

.Init will initialize locals.myMenuShow to false. So that you don't need to modify javascript code to do the initialization. It's often useful to control dialog, popups. At this example, We add it, So that the cancel button on the menu, could actually close the menu without requesting server backend.

toggleFavored event func did an partial update only to the favorite icon button. So that it won't close the menu popup, but updated the button to toggle the favorite icon.