1.0.2 • Published 7 years ago

vue2-notification-new v1.0.2

Weekly downloads
40
License
-
Repository
github
Last release
7 years ago

Vue2-notification-new


Installation:

Using NPM:

npm install vue2-notification-new --save

Using Yarn:

yarn add vue2-notification-new

Props:

Props NameTypeOptions
typeStringPrimary, Warning, Danger, Success, Info
durationNumbervalue in MilliSeconds

Events Fired:

Event NameComments
notification-closedEvent fired if notification is explicitly closed by user

Basic Usage:

Template

<notification type="danger" @notification-closed="closed">
    <img src="./assets/logo.png" alt="">
    <span>Lacus pulvinar veniam illum voluptates inceptos exercitation laoreet accumsan? Ullamco.</span>
</notification>

Script

import Notification from 'vue2-notification-new'

export default {
    components: {
        Notification
    },
    methods: {
        closed () {
            console.log('Notification was closed explicitly')
        }
    }
}

Setting Notification Duration:

Template

<notification type="danger" :duration="5000" @notification-closed="closed"> //Notification will disappears after 5sec
    <img src="./assets/logo.png" alt="">
    <span>Lacus pulvinar veniam illum voluptates inceptos exercitation laoreet accumsan? Ullamco.</span>
</notification>

Script

import Notification from 'vue2-notification-new'

export default {
    components: {
        Notification
    },
    methods: {
        closed () {
            console.log('Notification was closed explicitly')
        }
    }
}
1.0.2

7 years ago

1.0.16

7 years ago

1.0.15

7 years ago

1.0.14

7 years ago

1.0.13

7 years ago

1.0.12

7 years ago

1.0.11

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago