mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-15 18:01:24 +08:00
26 lines
417 B
Vue
26 lines
417 B
Vue
|
<template>
|
||
|
<el-input-number
|
||
|
v-model="num"
|
||
|
:min="1"
|
||
|
:max="10"
|
||
|
controls-position="right"
|
||
|
@change="handleChange"
|
||
|
/>
|
||
|
</template>
|
||
|
<script lang="ts">
|
||
|
import { defineComponent, ref } from 'vue'
|
||
|
|
||
|
export default defineComponent({
|
||
|
setup() {
|
||
|
const num = ref(1)
|
||
|
const handleChange = (value) => {
|
||
|
console.log(value)
|
||
|
}
|
||
|
return {
|
||
|
num,
|
||
|
handleChange,
|
||
|
}
|
||
|
},
|
||
|
})
|
||
|
</script>
|