import { ref } from 'vue'
import { defineStore } from 'pinia'

export const useLoader = defineStore('data', () => {
  const loader = ref<boolean>(false)

  function show() {
    loader.value = true
  }

  function hide() {
    loader.value = false
  }

  return {
    loader,
    show,
    hide,
  }
})
