Unleash awesomeness. Private packages, team management tools, and powerful integrations. Get started with npm Orgs »

vue-decorate

1.4.0 • Public • Published

vue-decorate

what

A simple component wrapper to add attributes and other kind of things to it's child

Use

  • download the package npm i -s vue-decorate

  • Plugin:

    import Decorate from 'vue-decorate'
    Vue.use(Decorate.Plugin)
    
    …
    
    export const MyComponent {
      template: '
      <v-decorate class="bar" type="text">
        <input class="foo" type="password">
      </v-decorate>
      ',
    }
    
  • Component:

    import Decorate from 'vue-decorate'
    
    export const MyComponent {
      components: { decorate: Decorate.component },
      template: '
      <decorate class="bar" type="text">
        <input class="foo" type="password">
      </decorate>
      ',
    }
    

install

npm i vue-decorate

Downloadsweekly downloads

8

version

1.4.0

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability