Skip to content
This repository has been archived by the owner on Feb 14, 2022. It is now read-only.

willsoto/vue-pickr

Repository files navigation

Vue Pickr

pipeline status coverage report

Vue component wrapping Pickr

Installation

npm install @willsoto/vue-pickr pickr-widget
yarn add @willsoto/vue-pickr pickr-widget

Usage

Template

<div>
  <vue-pickr @pickr="pickr" :options="options"></vue-pickr>
</div>

Script

import VuePickr from '@willsoto/vue-pickr';

export default {
  name: 'my-component',
  components: {
    VuePickr
  },
  data() {
    return {
      // gives you access to the pickr instance
      // https://github.com/Simonwep/pickr#methods
      pickr: null,
      // https://github.com/Simonwep/pickr#optional-options
      options: {}
    };
  }
};