Vijay Keshri
Vijay Keshri

Reputation: 507

Namespace 'Electron.CrossProcessExports' has no exported member 'Remote

I'm new to Electronjsenter image description here.

Error: node_modules/ngx-electron/lib/electron.service.d.ts:17:31 - error TS2694: Namespace 'Electron.CrossProcessExports' has no exported member 'Remote'.

17     readonly remote: Electron.Remote;

I hope anyone here, understands with this and is able to solve this. thank you! because my goal is to connect ipcMain, using ipcRenderer that I triggered on Angular Services.

Upvotes: 4

Views: 6316

Answers (4)

Daniel Kimaiga
Daniel Kimaiga

Reputation: 1

The solution that worked for me is found here https://github.com/ThorstenHans/ngx-electron/issues/71#issuecomment-1059796649

I went into ./node_modules/ngx-electron/lib/electron.service.d.ts and comment out this line:

// readonly remote: Electron.Remote;

It compiled fine, and using axious for http, rest, google access and authentication all my remote issues were handled.

Note that if you update the module you will have to reload it, or do a branch of this and use that instead.

Upvotes: 0

user19402686
user19402686

Reputation: 11

Go to the node_modules/ngx-electron/lib/electron.service.d.ts and comment the line -> readonly remote: Electron.Remote;

Upvotes: 1

Jack Doe
Jack Doe

Reputation: 514

A simple google search lead me to the issues section of the repository, and one issue in particular.

The user, named andelz, gave a pretty good answer regarding what might be wrong. By trial and error, I found a working solution that still contains no vulnerabilities (as of the moment of writing):

"ngx-electron": "2.2.0",
"electron": "13.6.6"

Upvotes: 3

Buchi
Buchi

Reputation: 506

In my case it turned out to be the electron version. If you are following the steps from this url https://buddy.works/tutorials/building-a-desktop-app-with-electron-and-angular on how to build an electron application with angular, ensure to install electron v5.0.6

Upvotes: 1

Related Questions