Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
CaiSijian authored Jun 5, 2024
1 parent e47b12d commit d07424b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
// @ts-check
/**@type {HTMLDivElement} */
const h1 = document.querySelector('h1')
h1.innerText='0.1.1'
h1.innerText='0.1.2'
const input = document.querySelector('input')
const textarea = document.querySelector('textarea')
input.addEventListener('keydown', (event) => {
const message = `${event.code} ${event.key}`
const message = `input event
${event.code} ${event.key}`
textarea.value = JSON.stringify(message)
})
window.addEventListener('keydown', (event) => {
const message = `${event.code} ${event.key}`
const message = `window event
${event.code} ${event.key}`
textarea.value = JSON.stringify(message)
})

0 comments on commit d07424b

Please sign in to comment.