1.0.51 • Published 4 years ago

vue-pwd-input v1.0.51

Weekly downloads
2
License
ISC
Repository
-
Last release
4 years ago

vue-pwd-input

vue 密码输入框插件| a password plugin

How to use

install

npm install --save vue-pwd-input

main.js/xxx.vue

import Vue from "vue";

import PwdInput from "vue-pwd-input";

Vue.use(PwdInput);

xxx.vue

<template>
  <pwd-input :max-length="6" ref="pwd" @blur="pwdBlur" @listenInput="listenInput"></pwd-input>
</template>
<script>
  data () {
    return {
      password: ''
    }
  },
  methods: {
    pwdBlur (password) {
      this.password = password            // get input password
    },
    listenInput (val) {
      console.log(val)                    // get input password
    },
    pwdFocus () {
      this.$refs.pwd.focusInput()
    },
    blur () {
      this.$refs.pwd.blur()               // blur
    },
    clear () {
      this.$refs.pwd.clear()              // clear input
    }
  }
</script>
1.0.51

4 years ago

1.0.9

4 years ago

1.0.8

4 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago