-
-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to use nx-electron #66
Comments
Hmm, do you mined trying the same with NX v9
|
It seems to work with NX@9. I can install everything but the electron view display a blank page. |
It might be, I have not explored NX@11. I have not release v10 yet 🙃. |
After making the build cross platform, i tested this with my nx-11 project with yarn link, which works fine. However when installed as a package, i get: tengable on auto-hide-sound [$!?] is 📦 v0.0.0 via ⬢ v14.14.0 on 🐳 v20.10.1 using ☁️ default/bubbles-298018 took 17s
➜ nx build tengable-electron --skip-nx-cache
> nx run tengable-electron:build
Unable to resolve nx-electron:build.
Cannot read property 'cyan' of undefined
|
@bennymeg is there a timeline yet for supporting version 11 of NX? |
Thank to @pascalbayer you will have a v11 released soon. |
I'm really looking forward to use nx-electron with v11! Do you have an idea of what's left to do before the v11 support will happen? |
@shlajin There is already an alpha version available to test |
@pascalbayer I fail at the very first step. I added
to my devDependencies, (then
The result is
I imagine I should start with v10, then upgrade to v11 and switch the package? |
Not sure what exactly you're trying, I guess the command should be different and is a copy&paste mistake. Can you maybe correct it and add more details on your setup? |
@pascalbayer Indeed, a copy-paste mistake, sorry.
and the produced error is
|
The command is:
So in your case it would be:
Please note that you should generate your frontend project (renderer) before you run this command |
Right... I wonder why I forgot about the I tried to use the
Oddly enough, it created a project; I tried to run it with a different name (e.g. named project |
Update: I tried to create a fresh nx workspace and I got the very same error again. Apparently it happens only in the very first time I run Update: it's a bumpy ride. I tried to start electron with
Googling this problem reveals that it's something to do with angular, but I don't use angular. The error in the previous message also states |
@shlajin I wasn't able to reproduce your issue by now. Haven't tried node 14 yet, takes some more time for testing that as well. Regarding |
@pascalbayer Tried fresh with node v12:
When I try to run I still get the same error.
Which node version do you use? |
@shlajin Thanks for that detailed description. I've been able to identify the issue. |
@shlajin please try |
@bennymeg tried with node v12.4.0 and node v14.15.4, I run the very same commands as in my previous post (except for the version of the lib, I run
|
@shlajin the root cause of the error is that your workspace.json file is in version 2, which I think can’t be handled by @angular-devkit anymore. I think with nx11 to handle the new version format we need to migrate all code to @nrwl/devkit. This seems to be more work then I thought initially. The reason why I never ran into that problem is that it works well with projects with either the original angular.json or workspace.json in version 1 configuration files. |
@pascalbayer i see... do you know if it’s possible to have nx v11 with v1 workspace? I use some new features from v11 and I also need an electron app... |
It seems we have mixed here two different issues. Feel free to finish you discussion here, but I think it will be more organized if we will move this discussion to #76. |
Describe the bug
I cannot create an electron app by following the instruction in the README.md file.
To Reproduce
Steps to reproduce the behavior:
npx create-nx-workspace@latest
yarn add -D @nrwl/react
nx g @nrwl/react:application test
yarn add -D nx-electron
nx g nx-electron:app test-electron --frontendProject=test
The behavior is the same if
10.0.0-beta.1
or9.3.2
is installed.Expected behavior
The command should generate a nx-electron application
Desktop:
EDIT: clarified the error message
The text was updated successfully, but these errors were encountered: