Vue Greetings
A vue component that returns greeting based on day, time and season. Ideal for welcome messages in dashboard and user profile
Installation
- Vue CLI
npm install vue-greetings
- script tag
<script src="https://unpkg.com/vue-greetings@0.1.7/dist/vue-greetings.min.js"></script>
Basic Use
- Register as a global component
import Vue from "vue";
import VueGreeting from "VueGreeting";
Vue.component("vue-greeting", VueGreeting);
then in vue components
<vue-greeting></vue-greeting>
- Register as Local Component
<template>
<div>
<vue-greetings/>
</div>
</template>
<script>
import VueGreetings from "vue-greetings"
export default {
components:{
VueGreetings
}
}
</script>
Demo
See live demo