Comments (11)
Yeah, don't install electron
directly onto the project. electron
is a dependency of electron-prebuilt-compile
(which is installed by default), but it does not install electron
into the top-level node_modules
(because of installation conflicts). What you're seeing with the red squiggle sounds like a VSCode bug.
from forge.
@MarshallOfSound it worked after
- reinstalling node
- installing electron-forge in global
- npm installing dependencies
from forge.
But it randomly stopped working on Windows 10
Nothing happens randomly, you probably deleted the .compilerc
by accident or corrupted your node_modules directory or something similar. On a fresh clone your repository I do not encounter this error so I can only assume that something has broken in your local.
Perhaps one of the issues mentioned above, perhaps not. You should try resetting your local dev environment.
from forge.
Nothing happens randomly, you probably deleted the .compilerc by accident
I do not know even where the .compilerc
file is. so am assuming did not delete it
where is the .compilerc file on windows and OSX ?
By random, i meant that it was working before and then stopped working
Can i request a electro-forge doctor
command to check the dependencies
I tried after reinstalling electron-forge
as well with "npm install -g electron-forge"
from forge.
If electron-forge start
get's passed the "Locating application" phase we believe the required config is there. This does not mean that you have everything installed correctly however.
Try completely recloning your repository, who knows what could have been deleted / edited / broken.
from forge.
thanks @MarshallOfSound. will try it out
from forge.
If electron-forge start get's passed the "Locating application"
phase we believe the required config is there
in my case the application is starting up but the above error is thrown
and this happens only on windows. application starts and works on OSX
there was a separate error on OSX
due to hard disk getting full. but there was no such issue on windows. ie. hard disk was not full etc
so not sure why this error is occurring
so i suggested a "homebrew doctor" command
so check all the dependencies
even a list of manual steps to check the system would be nice to have
re-installing the whole system (in case it stops working) does seems painful
from forge.
@deepak I'm not sure what to tell you, I cloned your repository onto a Windows 10 machine and ran yarn
followed by electron-forge start
. It worked perfectly.
Whatever error you are getting appears to be due to the compiler not kicking in which normally occurs due to a misconfigured .compilerc
.
As such the best I can suggest (as I said before) is effectively recloning your repository and starting the same way I did. If the error still occurs on a clean clone of your repository on your machine I can potentially look into more debugging
from forge.
Same error here but the steps described by deepak above does not help in my case.
from forge.
@krimark do you have a minimal, sample app that we can use to reproduce?
from forge.
Hi, what I do is to simply initialize a new projekt using the angular 2 template from here: https://beta.electronforge.io/templates and I also add electron to the dev dependencies with npm install electron --save-dev
because otherwise I get red squiggles in VS Code on the line import { app, BrowserWindow } from 'electron';
If I just run the code without first installing electron it seems to work but I don't understand why as electron is not present in node_modules at that time.
from forge.
Related Issues (20)
- Allow passing "copyright" config to DEB and RPM makers
- [ERR_MODULE_NOT_FOUND] [ESM] Vite doesn't bundle internal dependencies HOT 5
- Failed at Finalizing package HOT 2
- How to delete AppData folder when uninstall the App? HOT 2
- Error: Multiple plugins tried to take control of the start command, please remove one of them --> vite, fuses HOT 5
- Suggestions for Adding Frontend Framework Integration to the Electron Forge + Vite Template HOT 1
- Outdated ts typedefs/missing AbortSignal.timeout HOT 1
- using `electron/universal`, some modules do not rebuild according to `arch` HOT 3
- vite-plugin unable to make/package HOT 1
- Documentation for Webpack preload Scripts Is Not Correct
- Electron App Name & Icon single source of truth / documentation
- cannot publish to only github HOT 1
- Command for TypeScript templates broken on Windows HOT 4
- yarn error, but I'm not using yarn HOT 2
- `npm start` builds should allow a quick restart/reload option
- Load locale file in mainjs (vite)
- From template=typescript-webpack doesn't compile when using ipcRenderer HOT 2
- loadingGif
- Typescript ESM forge.config.ts error HOT 2
- If install @vueuse/core:^10.11.1 make failed on macOS HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from forge.