Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
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