"trannsition with vue js"
Bootstrap 4.1.1 Snippet by ALIMUL AL RAZY

<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css"> <script src="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js"></script> <script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <!------ Include the above in your HEAD tag ----------> <div class="container"> <div class="row"> <div id="demo"> <div class="col-md-6 col-md-offset-3"> <button class="btn btn-primary" @click="show = !show"> Show </button> </div> <br><br> <transition name="fade"> <div class="alert alert-info" v-if="show"> Howdy! How cool is VueJS ? </div> </transition> </div> </div> </div> <script src="https://cdn.jsdelivr.net/npm/vue@2.6.9/dist/vue.js"></script> <script> new Vue({ el: '#demo', data: { show: false } }) </script>
.fade-enter{ opacity: 0; } .fade-enter-active{ transition: opacity 1s; } .fade-leave{ /* opacity: 1; */ } .fade-leave-active{ transition: opacity 1s; opacity: 0; }

Related: See More


Questions / Comments: