Skip to content

LS1231/vue-security-code

Repository files navigation

vue-security-code

An security-code input implement by vue 2.0

Demo

Live Demo >>

Install

npm i -S vue-security-code

Usage

<template>
    <security-code v-model="code"></security-code>
</template>

<script>
    import SecurityCode from 'vue-security-code'

    // Declare
    export default {
        components: { SecurityCode },
        data () {
          return {
            code: ''
          }
        }
    }
</script>

Options

参数 说明 类型 可选值 默认值
length 长度 number 4
placeholder 占位符 string -
theme 主题 string block / line block

License

MIT Copyright (c) 2017 liusong