diff --git a/Userland/js.cpp b/Userland/js.cpp index 8f613fbfa6..21b9f87818 100644 --- a/Userland/js.cpp +++ b/Userland/js.cpp @@ -42,6 +42,7 @@ #include #include #include +#include #include Vector repl_statements; @@ -396,6 +397,15 @@ int main(int argc, char** argv) } editor = make(); + + signal(SIGINT, [](int) { + editor->interrupted(); + }); + + signal(SIGWINCH, [](int) { + editor->resized(); + }); + editor->initialize(); editor->on_display_refresh = [syntax_highlight](Line::Editor& editor) { auto stylize = [&](Line::Span span, Line::Style styles) {