vue-easily-notify

0.1.2 • Public • Published

Vue.js notifications, automatically adapt PC and mobile.

Demo: To be added. Github: To be added.

Install

npm install --save vue-easily-notify

How to

In main.js:

import Vue           from 'vue'
import Notifications from 'vue-easily-notify'
 
Vue.use(Notifications)

In any of your vue files:

this.$hnotify.success({
  text: 'success !',
  mode: 'root'
});
this.$hnotify.info({
  text: 'info !',
  mode: 'root'
});
this.$hnotify.warnning({
  text: 'warnning !',
  mode: 'root'
});
this.$hnotify.error({
  text: 'error !',
  mode: 'root'
});

API

  this.$hnotify({
    // root: Optional,default value is '',
    // Mode of the mobile size view. Based on the root tag's font-size,
    // When your html tag's font-size is 16 , it should be 'root',
    // Other cases it should be ''.
    root: '',
    // text: Content of notify action.
    text: 'This is content '
  })

Readme

Keywords

none

Package Sidebar

Install

npm i vue-easily-notify

Weekly Downloads

1

Version

0.1.2

License

none

Unpacked Size

208 kB

Total Files

12

Last publish

Collaborators

  • andy_h