MCPcopy Create free account
hub / github.com/PaulLeCam/react-native-electron / createWindow

Function createWindow

example/src/main.js:5–20  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3let appWindow = null
4
5const createWindow = () => {
6 appWindow = new BrowserWindow({
7 width: 800,
8 height: 600,
9 show: false,
10 webPreferences: {
11 preload: MAIN_WINDOW_PRELOAD_WEBPACK_ENTRY,
12 },
13 })
14
15 appWindow.once('ready-to-show', () => {
16 appWindow.show()
17 })
18
19 appWindow.loadURL(MAIN_WINDOW_WEBPACK_ENTRY)
20}
21
22const gotTheLock = app.requestSingleInstanceLock()
23

Callers 1

main.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected