Skip to content

Instantly share code, notes, and snippets.

@jakedohm
Last active April 28, 2022 05:17
Show Gist options
  • Save jakedohm/922481dbe3195decc4b5369661bc13cc to your computer and use it in GitHub Desktop.
Save jakedohm/922481dbe3195decc4b5369661bc13cc to your computer and use it in GitHub Desktop.
Smooth Reflow (Vue)
<template>
<SmoothReflow>
<div>My height will change at some point, and the SmoothReflow component
will automatically make sure that it animates</div>
</SmoothReflow>
</template>
<template>
<div>
<slot />
</div>
</template>
<script>
import smoothReflow from 'vue-smooth-reflow'
export default {
mixins: [smoothReflow],
mounted(){
this.$smoothReflow()
},
}
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment