New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

vue-notif

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vue-notif - npm Package Compare versions

Comparing version 1.1.5 to 1.1.6

src/icons/baseline-add_alert-24px.svg

5

package.json
{
"license": "MIT",
"version": "1.1.5",
"version": "1.1.6",
"author": "ctf0",

@@ -13,2 +13,5 @@ "name": "vue-notif",

},
"peerDependecies": {
"vue": "^2.0.0"
},
"dependencies": {

@@ -15,0 +18,0 @@ "vuemit": "^1.0.0"

88

README.md

@@ -13,55 +13,53 @@ # Vue Notif

**1-** register the component
- register the component "we use ***Bulma*** for styling the notification cards".
- we use ***Bulma*** for styling the notification cards.
```js
window.Vue = require('vue')
window.EventHub = require('vuemit')
```js
window.Vue = require('vue')
window.EventHub = require('vuemit')
Vue.component('MyNotification', require('vue-notif'))
```
Vue.component('MyNotification', require('vue-notif'))
```
- now call it either
**2-** now call it either
+ from html
- from html
```html
// for example when the backend is redirecting back with a msg
<div class="notif-container">
@if (session('status'))
<my-notification
icon="false"
title="title"
body="body"
type="success/error/primary/warning"
duration="1/2/etc..">
</my-notification>
@endif
</div>
```
```html
// for example when the backend is redirecting back with a msg
<div class="notif-container">
@if (session('status'))
<my-notification
icon="false"
title="title"
body="body"
type="success/error/primary/warning"
duration="1/2/etc..">
</my-notification>
@endif
</div>
```
+ or from js
- or from js
```js
EventHub.fire('showNotif',{
title: 'title',
body: 'body',
type: 'success',
duration: 1,
icon: false,
onClose(){
// what happen when notification is closed
}
});
```
```js
EventHub.fire('showNotif',{
title: 'title',
body: 'body',
type: 'success',
duration: 1,
icon: false,
onClose(){
// what happen when notification is closed
}
});
```
```html
<div class="notif-container">
<my-notification></my-notification>
</div>
```
```html
<div class="notif-container">
<my-notification></my-notification>
</div>
```
> - type > `default: info`
> - duration > `default: null` if not present, card will remain visible
> - icon > `default: true`
> - type : `default: info`
> - duration : `default: null` if not present, card will remain visible
> - icon : `default: true`

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc