Questions tagged [electron]

Electron (formerly Atom Shell) is a framework created by GitHub that lets you write cross-platform desktop applications using HTML, CSS and JavaScript. Electron is based upon Node.js and Chromium.

Electron (formerly Atom Shell) project was originally started by Cheng Zhao, one of the authors of NW.js (formerly known as node-WebKit), another Node.js-based platform for building desktop applications using HTML, CSS, and JavaScript. Cheng Zhao was hired by GitHub and began work on the framework on or about April 11th, 2013. On the 17th of April, 2015, with the release of version 0.24 the framework was renamed from Atom Shell to Electron.

One of the differences between Electron and NW.js frameworks is that the entry point for the app is actual JavaScript instead of an HTML page. This makes Electron more suitable for testing with PhantomJS, for instance.

Another difference is that the build process is also simpler for Electron using electron-builder, electron-forge and electron-packager. Since Electron uses libchromiumcontent to access Chromium's Content API, it's no longer required to obtain a copy of the Chromium source code. On that same note, the integration with Chromium is much more loosely coupled than in case of NW.js (which requires Chromium to be patched and maintained separately by the NW.js developers).

Probably, the most popular application built on top of Electron is a hackable text editor called Atom (also from GitHub). But there are some other interesting projects like Vivaldi Web browser, Mapbox Studio, an email client from Nylas, Slack desktop application, Pixate, Fireball game editor, Visual Studio Code, an SQL editor called Wagon, Mac app that runs Docker containers called Kitematic.


Resources :

15116 questions
4
votes
1 answer

In electron how to send custom header and value for every request?

I use electronjs for building a cross platform desktop application. I would like to send a custom header with a value for every request from electron. Initially in loadURL(), i could use extraHeaders to set the custom header. How to send it in all…
4
votes
1 answer

How to exclude package from being installed via symlink in pnpm?

I have an Electron project and used pnpm due to it's significant speedup when installing modules over npm or yarn. However, 1 module has a problem by being installed via a symlink in the node_modules directory. Is there any way to exclude a…
Daniel Stephens
  • 2,371
  • 8
  • 34
  • 86
4
votes
1 answer

How to rename file with google drive api v3? electron, nodejs

for v2, we can get an example how to rename file with google drive API. here's the link https://developers.google.com/drive/api/v2/reference/files/patch#examples here's how we can rename a file with v2 in javascript /** * Rename a file. * *…
dhanyn10
  • 704
  • 1
  • 9
  • 26
4
votes
1 answer

Electron was compiled against a different Node.js version

I'm building an Electron application that is expected to run on Ubuntu 20.xx Linux and a Raspberry Pi (Running Raspbian and arch=armv7l) and received the following error: ...was compiled against a different Node.js version using NODE_MODULE_VERSION…
Luke Bayes
  • 3,234
  • 2
  • 25
  • 20
4
votes
0 answers

Compile Python runtime inside of electron app

I am using electron and python together. I've gone through all the youtube videos and forums I can find on the subject of packaging an app with a python backend. Many of these tutorials are out of date and no longer work. This is my process so far.…
4
votes
3 answers

Incorrect NODE_MODULE_VERSION when using ava

I write an Electron app that uses nodegit. For my test part I use ava in combination with Spectron to test my app. All of my tests work - including functions which use nodegit in my app. In addition to the tests described above I made also a pure…
Daniel Stephens
  • 2,371
  • 8
  • 34
  • 86
4
votes
1 answer

EJS not rendering after using electron builder

I am trying to render an ejs file in my electron.js app. I am loading the ejs file using the following skeleton: const ejs = require('ejs') ejs.renderFile('views/list.ejs', { data: listData }, { root: __dirname }, function (err, str) { if…
akshayks
  • 199
  • 9
4
votes
1 answer

node ffi - GetWindowRect

I am building a Windows Electron app that will move and resize an active window. I am using ffi-napi to access user32 specific functions such as GetForegroundWindow, ShowWindow, & SetWindowPos. const ffi = require('ffi-napi'); // create foreign…
Neo Genesis
  • 922
  • 11
  • 26
4
votes
1 answer

How to Secure SQLite database?

We have a windows application which is written by electron and SQLite as database, the problem is we want our application to secure the database file after its first authentication with database, and only have the application itself can modify the…
4
votes
0 answers

How to share the server code to electron app?

I am developing a postman like application with some added features. For the frontend, I am using Angular 10, and for the backend, I am using node with fastify.js and for the database, I am using MongoDB via Atlassian MongoDB hosting. Right now, I…
Raj Thakar
  • 198
  • 9
4
votes
0 answers

Electron BrowserWindow hangs and becomes unresponsive

We have builds of our application for mac and window with the Electron framework. And a lot of our users complain that the application sometimes hangs and becomes unresponsive. The Sentry monitoring shows that we have a lot of reports about that app…
blackart
  • 86
  • 5
4
votes
5 answers

TypeError: Cannot read property 'whenReady' of undefined

i have a problem with electron. TypeError: Cannot read property 'whenReady' of undefined i use node 14.0.1 electron 10.1.2 i run my app "electron:serve": "vue-cli-service electron:serve", my background.js const { app, BrowserWindow } =…
Ruslav Ivanov
  • 41
  • 1
  • 4
4
votes
0 answers

desktopCapturer - how to prove audio is coming through?

I have the following code that attempts to capture audio/video from a specific application running on my windows desktop: Audio and Video
dot
  • 14,928
  • 41
  • 110
  • 218
4
votes
0 answers

Electron forge webpack remove renderer config

I use Electron Forge with the webpack template. For the renderer i use an url (mainWindow.loadURL(startURL);) and want to remove everything in the webpack config that has to do with the renderer. Is there a way to use the webpack template without…
4
votes
0 answers

React/Electron Production Build giving CORS error when loading manifest.json from index.hml

I am trying to turn my react webapp into a standalone desktop application using electron. (Full disclosure, I've never used electron before) Getting it running in development mode was amazingly easy. All of my react elements are rendered nicely,…
1 2 3
99
100