Open a-kriya opened 4 years ago
It would reduce duplication and declutter templates if the plugin allowed overriding defaults:
import Vue from 'vue' import VueObserveVisibility from 'vue-observe-visibility' Vue.use(VueObserveVisibility, { once: true })
If majority of my use cases require once to be set to true, then I can just do that, and if I need to set it to false occasionally, I can still do:
once
<div v-observe-visibility="{ callback: visibilityChanged, once: false, }">
This applies to all options, and so could also resolve #201.
It would reduce duplication and declutter templates if the plugin allowed overriding defaults:
If majority of my use cases require
once
to be set to true, then I can just do that, and if I need to set it to false occasionally, I can still do:This applies to all options, and so could also resolve #201.