notification.vue 329 B

1234567891011121314151617
  1. <template>
  2. <div>notify</div>
  3. </template>
  4. <script lang="ts" setup>
  5. import { getCurrentInstance } from 'vue'
  6. const vm = getCurrentInstance()!
  7. const notify = vm.appContext.config.globalProperties.$notify
  8. notify({
  9. title: 'Prompt',
  10. message: 'This is a message that does not automatically close',
  11. duration: 0,
  12. })
  13. </script>