Captain is currently in ALPHA. We are happy to get your feedback
Core API
Helpers Utils Create Window

Module: helpers/utils/create-window

Table of contents

Functions

Functions

createWindow

createWindow(windowName, options): Promise<BrowserWindow>

Creates a new Electron BrowserWindow with specified options. Manages window state using electron-store to remember its size and position. Sets up IPC handler for opening directory dialogs.

Parameters

NameTypeDescription
windowNamestringThe name of the window, used for state persistence.
optionsBrowserWindowConstructorOptionsOptions for the BrowserWindow.

Returns

Promise<BrowserWindow>

A promise that resolves to the created BrowserWindow instance.

Defined in

src/electron/helpers/utils/create-window.ts:22 (opens in a new tab)