question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

electron-prebuilt renamed

See original GitHub issue

http://electron.atom.io/blog/2016/08/16/npm-install-electron

I went ahead and updated my project and removed prebuilt.

My code is:

require('electron-reload')(__dirname, {
        electron: require('electron')
    });

but I get “Electron could not be found. No hard resets for you!” when I start my app…

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:19 (7 by maintainers)

github_iconTop GitHub Comments

28reactions
ghostcommented, Oct 30, 2016

Looks to be related to the way require works, when using the new package name

Previously the index.js file would be loaded returning the path to the executable, Instead the electron.asar is loaded.

I was able to work around this by providing a path to the index.js inside the module home instead.

require('electron-reload')(__dirname, {
  electron: require('${__dirname}/../../node_modules/electron')
})
3reactions
Eshvacommented, Jul 4, 2018

@rachidsakara Thank you for comment. It helped me. But the only thing you need to fix are quotes. You should use ` not ’ for interpolation.

For instance the proper version of Option 3 is: require('electron-reload')(__dirname, { electron: require(`${__dirname}/node_modules/electron`) })

Read more comments on GitHub >

github_iconTop Results From Across the Web

electron-prebuilt has been renamed to electron #833 - GitHub
npm WARN deprecated electron-prebuilt@1.4.3: electron-prebuilt has been renamed to electron.
Read more >
'electron-prebuilt has been renamed to just 'electron' (https://electron ...
'electron-prebuilt has been renamed to just 'electron' (https://electron.atom.io/blog/2016/08/16/npm” is published by Niek van de Pas.
Read more >
electron-prebuilt - npm
This package has been deprecated. Author message: electron-prebuilt has been renamed to electron.
Read more >
electron-prebuilt | Yarn - Package Manager
electron-prebuilt has been renamed to electron. For more details, see http://electron.atom.io/blog/2016/08/16/npm-install-electron.
Read more >
Application Packaging | Electron
To distribute your app manually, you need to download Electron's prebuilt binaries. Next, the folder containing your app should be named app and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found