@coleman.rg/vue-options-plugin

1.0.1 • Public • Published

optionsplugin

A demo of making a simple Vue 2 plugin and using it with values stored in the options object. This plugin logs out to the console the number of characters in an element. It also adds different CSS styles based on the length of characters in the element.

Installation

 npm install --save optionsplugin

Configuration

import Vue from 'vue';
import OptionsPlugin from 'optionsplugin'
Vue.use(OptionsPlugin, {
  selectedOption: {
    plum: "5px dashed purple",
    orange: "10px double orange"
  }
})

Usage

To use it, simply add the plugin's custom directive of v-text-length to an element in your template's code.

Readme

Keywords

none

Package Sidebar

Install

npm i @coleman.rg/vue-options-plugin

Weekly Downloads

0

Version

1.0.1

License

ISC

Unpacked Size

1.56 kB

Total Files

3

Last publish

Collaborators

  • coleman.rg