From 0a8c86a9d98dde497bd8b6477a7202b375bdfcf3 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Fri, 7 Oct 2022 13:35:40 +0200 Subject: [PATCH] Ladybird: Load about:blank in new tabs This makes the JS console usable in new tabs, without having to load something first. --- Ladybird/Tab.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Ladybird/Tab.cpp b/Ladybird/Tab.cpp index f19ac4941b..9982099b9d 100644 --- a/Ladybird/Tab.cpp +++ b/Ladybird/Tab.cpp @@ -97,6 +97,10 @@ Tab::Tab(BrowserWindow* window) text_edit->setPlainText(source); text_edit->show(); }); + + // FIXME: This is a hack to make the JS console usable in new windows. + // Something else should ensure that there's an initial about:blank document loaded in the view. + m_view->load("about:blank"sv); } void Tab::focus_location_editor()