<template> <div> <input v-model="data1" type="text" @keyup.F12="add"> </div> </template> <script> export default { data(){ return{ data1:15 } },methods:{ add(){ alert("ssss") } } } </script>