webnoobcodes / vuejs-accordion

This nice animated accordion here has a smooth opening and closing transition. On top, you have an arrow for each element, which rotates if you click an item in the list.

Home Page:https://youtu.be/zgIshnTiNjM

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Menu Accordion Animation

That's the complete source code with comments from the video tutorial Menu Animation with Vue

Menu Animation with Vue transitions. This nice animated accordion here has a smooth opening and closing transition. On top, you have an arrow for each element, which rotates if you click an item in the list.

Now, if you need to animate an HTML element from zero height to its natural height, then that can be quite problematic. The element just appears directly, instead of an animation.

There are some solutions to fix this age-old problem, like if you use the min-height attribute or the scaling with transform, but all of these methods have their disadvantages. So using JavaScript for triggering and controlling transitions is almost essential.

And Vue.js provides us a beautiful transition component which makes animating HTML elements a very pleasant experience. So there are hardly any reasons not to use JavaScript to animate elements if you are using Vue JS.

Tutorial on Youtube

📺 Complete Playlists

Learn Vue JS - From The Ground Up

Learn Vue JS - Additional Libaries

Best Vue JS Tips and Tricks

Vue JS Animations and Transitions

Learn Nuxt JS - From The Ground Up

Connect with me:

weboob.dev webnoob | YouTube webnoob | Twitter webnoob | Instagram webnoob | BuyMeACoffee



Project setup

npm install

Compiles and hot-reloads for development

npm run serve

Compiles and minifies for production

npm run build

Run your tests

npm run test

Lints and fixes files

npm run lint

License

MIT

About

This nice animated accordion here has a smooth opening and closing transition. On top, you have an arrow for each element, which rotates if you click an item in the list.

https://youtu.be/zgIshnTiNjM

License:MIT License


Languages

Language:Vue 88.6%Language:HTML 8.4%Language:JavaScript 3.1%