-
-
Notifications
You must be signed in to change notification settings - Fork 15
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
How to use this tool? #161
Comments
I am in the same place as you, no idea how to package my app into .exe file. |
I'm in the same boat. Can't build for Windows at all. |
Currently the README page does not mention it, but the "dist" folder content is make with webpack, so you must add it as a dev dependency. Webpack pack index.js in a .node file but some content can't be packed directly so need of plugins to be packed, so those need to be installed too. The plugins used in the starter repo are ts-loader (for typescript), file-loader (for images) and native-addon-loader (for nodejs), to make them work, you will need a webpack.config.js file that will be in the root folder of your project. In my particular case the webpack.config.js settings from the starter repo was not useful, i don't use typescript and native-addon+ file-loader were giving me two .node files that weren't working, so i ended up doing a different settings by using native-ext-loader since native-addon was hard to configure alone o_o, anyway, i will leave it here in case someone find it useful.
|
You should build a dist directory before packing it:
|
How to use this tool?
simplest
package.json
:all my code is a
index.js
:npx nodegui-packer --init MyAppName
#generatedisplay
folder. I don't touch anything inside.create a
dist
folder, then put all my code (just aindex.js
file) into this folder.npx nodegui-packer --pack ./dist
result:
relative:
#112
...and I find out electron's doc is more user friendly to a newbie...
The text was updated successfully, but these errors were encountered: