Questions tagged [electron-packager]

Use electron-packager for questions related to the packaging module for Electron apps

References

493 questions
43
votes
5 answers

electron package: reduce the package size

I made a simple Electron app: main.js const {app, BrowserWindow} = require('electron') const path = require('path') const url = require('url') let win function createWindow () { win = new BrowserWindow({ width: 800, height: 600, …
ar099968
  • 6,963
  • 12
  • 64
  • 127
19
votes
6 answers

'electron-packager' is not recognized as an internal or external command

I recently started using electron. I have successfully completed the 1st phase by creating a hello world app (included files index.html, main.js, package.json). Now I am trying to package the app using electron-packager but getting this error Steps…
Sidharth Gusain
  • 1,473
  • 1
  • 13
  • 20
14
votes
1 answer

How to solve this error Module not found: Error: Can't resolve 'fs'

I have created new angular project with electron.I do need to set up the electron. I have got below errors. ERROR in ./node_modules/electron/index.js Module not found: Error: Can't resolve 'fs' in 'D:\PATH\desktop\node_modules\electron' My…
Manoj Ghediya
  • 547
  • 1
  • 7
  • 19
14
votes
3 answers

How to pass an argument to electron when using electron-builder?

I'm building an application with Electron and packaging with Electron Builder. When running electron, I want to pass this command line argument: --enable-mixed-sandbox. Is it possible? How? This: …
Pablo Fernandez
  • 279,434
  • 135
  • 377
  • 622
13
votes
3 answers

How to use auto-launch to start app on system startup?

package.json: { "name": "electronapp", "version": "1.0.0", "description": "electron auto-launch", "main": "index.js", "scripts": { "start": "electron .", "build": "electron-packager . --all" }, "author": "ivie", "license":…
user8317956
12
votes
8 answers

Electron shows white screen when built

I'm learning electron and I've made an electron app that read and create files. When I start the application with npm start or electron . it works as intended: But when I use npm run build or build -w commands, the application built just shows a…
11
votes
3 answers

Electron executable not recognized by Nautilus

I'm not able to build an executable file of an Electron App with the following command: electron-packager . electron-tutorial-app --overwrite --asar=true --platform=linux --arch=x64 --prune=true --out=release-builds The build file, which is a…
Catalyst
  • 465
  • 6
  • 14
11
votes
2 answers

preload script not loaded in packaged app

I've made a small Electron app which needs to load a preload js file. When I start the app with electron ., it finds the file, but when the app is packaged, it doesn't. The call is made here: mainWindow = new BrowserWindow({ width: 800, …
Sergio
  • 183
  • 1
  • 9
10
votes
1 answer

Increase Electron Memory limit

My electron app crashes as soon as the memory usage reaches 2,000 MB. I can test it by having this code in my main process file which intentionally raises the memory usage: const all = []; let big = []; all.push(big); for (let i = 0;…
9
votes
1 answer

Electron electron-winstaller fails to create installers for large (filesize) app

I am trying to create a Windows installer for a electron app. First the app is packaged with electron-packager. exec(`npx electron-packager ./ "My App Name" --platform=win32 --out=${packagedLocation}`); Then the app's installer is created using…
9
votes
1 answer

How should i exclude all node_modules in electron-packager

I'm using electron-packager for creating an electron.exe of my app. I need to exclude all node modules . I tried the following --ignore=node_modules The above is not working. Any idea how to exclude all folders/ remove node modules in final build.
arun thatham
  • 500
  • 1
  • 4
  • 13
9
votes
3 answers

convert angular 4 application to desktop application using electron

I have developed application using angular 4. I need to develop desktop application for this web application . From my initial research i got the best solution is electron. Any one please suggest the steps to convert angular 4 application to…
Sarath
  • 1,459
  • 3
  • 22
  • 38
9
votes
1 answer

How to properly include twitter bootstrap in electron app?

This is my first electron app, which is based on quick-start app. I want to add twitter bootstrap's css. So I installed it like this: npm install bootstrap And included in the index.html like this:
Lamar
  • 1,761
  • 4
  • 24
  • 50
8
votes
2 answers

Electron Tray Icon doesn't show after once I package

I've got an Electron app that shows a tray icon, which, when clicked, shows my main window. works great in development mode, but when I package it, (into a .app file), and double click the .app file, none of the menus show up, and more importantly,…
raingod
  • 1,377
  • 1
  • 11
  • 24
8
votes
1 answer

File association with electron builder

I’m making a multi platform application with Electron and I’m trying to make the file association using electron-builder. I’ve added it to the configuration and that works fine, when I double click on a file, it opens the app, which is expected, but…
Javis Perez
  • 4,130
  • 3
  • 23
  • 27
1
2 3
32 33