fix backspace in shell

This commit is contained in:
Remko Tronçon 2022-04-17 17:12:32 +02:00
parent ef0a360366
commit 0f0335568b

View file

@ -33,8 +33,8 @@ function unoutput(isInput) {
}
function startConsole() {
let inputbuffer = [];
document.addEventListener("keypress", (ev) => {
// console.log(ev);
document.addEventListener("keydown", (ev) => {
// console.log("keydown", ev);
if (ev.key === "Enter") {
output(" ", true);
forth.run(inputbuffer.join(""));