commit | author | age | ||
778328 | 1 | const app = Vue.createApp({ |
CM | 2 | data() { |
3 | return { | |
4 | messaggio: "Hi Alert!", | |
5 | kdInput: "", | |
6 | keInput: "", | |
7 | }; | |
8 | }, | |
9 | methods: { | |
10 | myAlert() { | |
11 | alert(this.messaggio); | |
12 | }, | |
13 | myKeydown(event){ | |
14 | this.kdInput = event.target.value; | |
15 | }, | |
16 | myKeyEnter(event){ | |
17 | this.keInput = event.target.value; | |
18 | } | |
19 | }, | |
20 | }); | |
21 | ||
22 | app.mount("#assignment"); |