Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tahq69/vue-notice
VueJs notice component
https://github.com/tahq69/vue-notice
Last synced: about 2 months ago
JSON representation
VueJs notice component
- Host: GitHub
- URL: https://github.com/tahq69/vue-notice
- Owner: tahq69
- License: mit
- Created: 2017-11-23T14:41:25.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2017-12-30T18:07:58.000Z (about 7 years ago)
- Last Synced: 2024-11-11T03:44:23.063Z (about 2 months ago)
- Language: Vue
- Size: 1.15 MB
- Stars: 11
- Watchers: 3
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# crip-vue-notice
A Vue.js project to add global notices on a page. Take a look to [demo page](http://rawgit.com/tahq69/vue-notice/master/index.html)
![Preview](http://rawgit.com/tahq69/vue-notice/master/dist/Capture.PNG)
## Usage
### Install
```bash
> npm i -S crip-vue-notice
```### Prerequisites
- [Font Awesome](http://fontawesome.io/): Add font awesome css to make ikons in notices visible:
```html
...
```
### Setup
```javascript
import Vue from 'vue'
import CripNotice from 'crip-vue-notice'// Install component in to Vue instance.
Vue.use(CripNotice)
```### Display notification
```vue
// App.vue
Normal
Error
Info
Success
Warning
export default {
methods: {
notice (type) {
this.$notice[type]({
title: `Notice of ${type} type`,
description: `Notice of ${type} type was clicked and it popped up!`
})
},
},
}```
## Build Setup
```bash
# install dependencies and serve with hot reload at localhost:8080
> npm i && npm run dev
```## Release steps
```bash
> npm run release
```