mirror of
https://github.com/remko/waforth
synced 2025-01-19 22:26:17 +01:00
fix backspace in shell
This commit is contained in:
parent
ef0a360366
commit
0f0335568b
1 changed files with 2 additions and 2 deletions
|
@ -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(""));
|
||||
|
|
Loading…
Reference in a new issue