(props, { emit })
| 77 | props: ['value'], |
| 78 | emits: ['update'], |
| 79 | setup(props, { emit }) { |
| 80 | return () => |
| 81 | h('input', { |
| 82 | type: 'number', |
| 83 | value: props.value, |
| 84 | onInput: (e: InputEvent) => { |
| 85 | const num = (e.target! as HTMLInputElement).valueAsNumber |
| 86 | emit('update', Number.isNaN(num) ? null : num) |
| 87 | }, |
| 88 | }) |
| 89 | }, |
| 90 | }) |
| 91 | customElements.define('my-el-input', CustomInput) |
| 92 | const num = ref('12') |
nothing calls this directly
no test coverage detected