插件名称 | vue-notifyjs |
---|---|
发布时间 | 2021年1月15日 |
插件作者 | cristijora |
Vue.js的最小,可主题化,可删除的通知组件。
# Yarn
yarn add vue-notifyjs
# NPM
$ npm install vue-notifyjs
<template>
<notifications></notifications>
</template>
<script>
import Notify from 'vue-notifyjs'
Vue.use(Notify)
export default {
methods: {
addNotification() {
this.$notify({
message: 'Welcome',
type: 'success'
})
}
}
}
</script>
<!-- import styles -->
<style src="vue-notifyjs/themes/default.css"></style>