martywallace / vue-keyboard

A simple virtual keyboard for Vue.js.
MIT License
153 stars 16 forks source link

There are some problems on custom key #24

Closed Jrexexe closed 6 years ago

Jrexexe commented 6 years ago

[Vue warn]: Error in event handler for "match": "TypeError: undefined is not a function"

found in

   <keyboard
            @match="matchGame"
            layouts="123456|7890{←:backspace}{ok:match}"
            v-model="awayPkCode"
            :maxlength="4"/>
martywallace commented 6 years ago

It looks like the error is emitted from your event handler i.e. matchGame.

Jrexexe commented 6 years ago

my handler

     matchGame() {
        console.log('.....');
      }
Jrexexe commented 6 years ago

@MartyWallace error info

[Vue warn]: Error in event handler for "match": "TypeError: undefined is not a function"

found in

---> <Keyboard> at node_modules\vue-keyboard\src\keyboard.vue
       <ElCol>
         <ElRow>
           <VueJsModal> at /Users/yev.vlasenko2/Projects/vue/vue-js-modal/src/Modal.vue
             <ElContainer>
               <ModeTraining> at src\components\mode-intro\mode-challenge.vue
                 <App> at src\App.vue
                   <Root> 
Jrexexe commented 6 years ago

rebuild then ok 。thanks