Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

We are able to ran the Electron desktop application by using electron-builder along with dmg on X64.If we want to run same application on apple silicon(ARM64), We installed following dependancies(X64)
1 Xcode 12 and upgrade Mac to Bix sur.
2 "npm install [email protected]"
3 node-gyp(7.1.2)

but, found below errors:

"ERROR TypeError: Cannot read property 'require' of null"

Also while building and packaging the application we want to add extraFiles. Kindly suggest if any solution.

Also read about electron-packager,but How can we add extra files using the same.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
349 views
Welcome To Ask or Share your Answers For Others

1 Answer

I don't know how to resolve your error but I can suggest to you to install the latest electron release and not a beta version. If you think the beta can be the best way to use with an apple silicon (I don't now if the latest beta is compiled for it) you can try it equally, because macOS will compile electron for you... (it can takes about 20 seconds to compile).


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share

548k questions

547k answers

4 comments

86.3k users

...