vue-smooth-fade

0.0.15 • Public • Published

Vue 3 Smooth Fade

Vue 3 plugin for smooth hiding and showing content

Demo

Demo

Installation

npm i vue-smooth-fade

Usage

Inside vue components use:

<script setup>
    import { SmoothFade } from 'vue-smooth-fade'
    import { ref } from 'vue'
    
    const show = ref(false)
</script>

<template>
    <SmoothFade v-model="show">
        <div>
            ........
        </div>
    </SmoothFade>
    
    <a href="#" @click.prevent="show = !show">Toggle</a>
</template>

Props

Attribute Type Default Description
duration Number 700 show and hide duration
easing String ease-in-out easing
overflow Boolean false Set overflow:hidden to parent element

Package Sidebar

Install

npm i vue-smooth-fade

Weekly Downloads

4

Version

0.0.15

License

MIT

Unpacked Size

18.4 kB

Total Files

14

Last publish

Collaborators

  • tvbird