export default {
    install(Vue) {
        Vue.directive('preventReClick', {
            inserted(el, binding) {
                el.addEventListener('click', () => {
                    const events = el.style.pointerEvents
                    if (events == "") {
                        el.style.pointerEvents = 'none'
                        setTimeout(() => {
                            el.style.pointerEvents = "";
                        }, binding.value || 1000);
                    }

                })
            }
        })
    }
}