vue-floating-alert
A floating alert for vue2+ projects
715
3
| Install | |
|---|---|
npm install vue-floating-alert |
|
| Latest Version: | 1.0.5 |
| Vue: | 2 |
| License: | MIT |
| Last Updated: | Dec 9, 2022 |
| Links: | GitHub · npm |
Maintainer: ericmdantas
vue-floating-alert
Install
$ npm i --save vue-floating-alert
Usage in components
// app.vue
<template>
<div>
<FloatingAlert language="pt-BR" />
</div>
</template>
<script>
import Vue from 'vue'
import VueFloatingAlert from 'vue-floating-alert'
Vue.use(VueFloatingAlert)
export default {
mounted() {
setTimeout(() => {
this.$floatingAlert.success({
title: 'Success!',
message: 'Woohoo! <i class="fa fa-fw fa-grin-wink"></i>',
})
}, 1000)
},
}
</script>
Usage in other files
// app.vue
import {floatingAlert} from 'vue-floating-alert'
export default {
doSomething() {
floatingAlert.success({
title: 'Success!',
message: 'Woohoo! <i class="fa fa-fw fa-grin-wink"></i>',
})
},
}
Methods
this.$floatingAlert.error({
message: "That's an error :(",
})
this.$floatingAlert.warn({
title: "Hey you",
message: "Be careful with that",
})
this.$floatingAlert.info({
title: 'Just to let you know',
message: "We'll send you an email when we're finished",
})
this.$floatingAlert.success({
title: "Awesome!",
message: "You've finished reading all your emails. Now go play outside.",
})
// if you don't want to wait, you can close it on your own
this.$floatingAlert.hide()
License
MIT
Related Packages
@gits-id/alert
GITS Alert component is a flexible alert component that can be used to display v...
3,784
Version History
| Version | Released | Vue | License |
|---|---|---|---|
| 1.0.5 | ^2.2.10 | MIT | |
| 1.0.4 | ^2.2.10 | MIT | |
| 1.0.3 | ^2.2.10 | MIT | |
| 1.0.2 | ^2.2.10 | MIT | |
| 1.0.1 | ^2.2.10 | MIT | |
| 1.0.0 | ^2.2.10 | MIT | |
| 0.0.17 | ^2.2.10 | MIT | |
| 0.0.16 | ^2.2.10 | MIT | |
| 0.0.15 | ^2.2.10 | MIT | |
| 0.0.14 | ^2.2.10 | MIT | |
| 0.0.13 | ^2.2.10 | MIT | |
| 0.0.12 | ^2.2.10 | MIT | |
| 0.0.11 | ^2.2.10 | MIT | |
| 0.0.10 | ^2.2.10 | MIT | |
| 0.0.9 | ^2.2.10 | MIT | |
| 0.0.8 | ^2.2.10 | MIT | |
| 0.0.7 | ^2.2.10 | MIT | |
| 0.0.6 | ^2.2.10 | MIT | |
| 0.0.5 | ^2.2.10 | MIT | |
| 0.0.4 | ^2.2.10 | MIT | |
| 0.0.3 | ^2.2.10 | MIT | |
| 0.0.2 | ^2.2.10 | MIT |