using require
See original GitHub issueHow could I use this:
import installExtension, { REACT_DEVELOPER_TOOLS } from ‘electron-devtools-installer’;
installExtension(REACT_DEVELOPER_TOOLS)
.then((name) => console.log(Added Extension: ${name}))
.catch((err) => console.log('An error occurred: ', err));
With node require imports?
Issue Analytics
- State:
- Created 7 years ago
- Comments:9 (4 by maintainers)
Top Results From Across the Web
Requiring modules in Node.js: Everything you need to know
Node uses two core modules for managing module dependencies: The require module, which appears to be available on the global scope — no...
Read more >What is this JavaScript "require"? - Stack Overflow
the CommonJS (CJS) format, used in Node.js, uses a require function and module.exports to define dependencies and modules. The npm ecosystem is built...
Read more >How NodeJS Require works! | Thirdock Techkno
require () is used to consume modules. It allows you to include modules in your app. You can add built-in core Node.js modules,...
Read more >What is require? - Node.js
The basic functionality of require is that it reads a JavaScript file, ... example2.js')() //require itself and run the exports object.
Read more >Using import and require in the same file - Node JS - YouTube
Found solution here: https://www.kindacode.com/article/node-js-how-to-use-import-and- require -in-the-same-file/
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Ok, I was calling the methods before the app is ready.
Calling them inside the createWindow function fixed the errors
That throws this error