diff --git a/src/app/editorgrid.ts b/src/app/editorgrid.ts index 08eac54..6e910d1 100644 --- a/src/app/editorgrid.ts +++ b/src/app/editorgrid.ts @@ -24,6 +24,8 @@ export function addEditor(file: OpenFile) { console.log("Adding editor to tab ", currentTab.val, editors); const editor = file.createEditor(); editors[currentTab.val].push(vanX.noreactive(editor)); + editor.view.dom.scrollIntoView(); + editor.view.focus(); } export function addTab(file?: OpenFile) {