Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ssougnez/61378202b96c23d8b6468af73aa26aa7 to your computer and use it in GitHub Desktop.
Save ssougnez/61378202b96c23d8b6468af73aa26aa7 to your computer and use it in GitHub Desktop.
import "./assets/css/main.css"
const divMessages: HTMLDivElement = document.querySelector("#divMessages");
const tbMessage: HTMLInputElement = document.querySelector("#tbMessage");
const btnSend: HTMLButtonElement = document.querySelector("#btnSend");
const username = new Date().getTime();
tbMessage.addEventListener("keyup", (e: KeyboardEvent) => {
if (e.keyCode === 13) {
send();
}
});
btnSend.addEventListener("click", send);
function send() {
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment