Skip to content

Commit 6c5c629

Browse files
committed
adds packing docs
1 parent e1499f0 commit 6c5c629

File tree

2 files changed

+50
-21
lines changed

2 files changed

+50
-21
lines changed

website/docs/guides/packaging.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
---
2+
sidebar_label: Packaging
3+
title: Packaging
4+
---
5+
6+
In order to distribute your finished app, you can use [@nodegui/packer](https://github.com/nodegui/packer)
7+
8+
- **Step 1: (Run this command only once)**
9+
10+
```sh
11+
npx nodegui-packer --init MyAppName
12+
```
13+
14+
This will produce the deploy directory containing the template. You can modify this to suite your needs. Like add icons, change the name, description and add other native features or dependencies. Make sure you commit this directory.
15+
16+
- **Step 2: (Run this command every time you want to build a new distributable)**
17+
18+
Next you can run the pack command:
19+
20+
```sh
21+
npm run build
22+
```
23+
24+
This will produce the js bundle along with assets inside the ./dist directory
25+
26+
```sh
27+
npx nodegui-packer --pack ./dist
28+
```
29+
30+
This will build the distributable using @nodegui/packer based on your template. The output of the command is found under the build directory. You should gitignore the build directory.
31+
32+
More details about packer can be found here: https://github.com/nodegui/packer

website/sidebars.js

Lines changed: 18 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module.exports = {
2-
"api": {
3-
"Components": [
2+
api: {
3+
Components: [
44
"api/interfaces/buttonprops",
55
"api/interfaces/checkboxprops",
66
"api/interfaces/dialprops",
@@ -13,15 +13,11 @@ module.exports = {
1313
"api/interfaces/spinboxprops",
1414
"api/interfaces/textprops",
1515
"api/interfaces/viewprops",
16-
"api/interfaces/windowprops"
16+
"api/interfaces/windowprops",
1717
],
18-
"Others": [
19-
"api/globals"
20-
],
21-
"Modules": [
22-
"api/modules/_react_proxy_"
23-
],
24-
"Interfaces": [
18+
Others: ["api/globals"],
19+
Modules: ["api/modules/_react_proxy_"],
20+
Interfaces: [
2521
"api/interfaces/_react_proxy_.reactproxycomponent",
2622
"api/interfaces/abstractbuttonprops",
2723
"api/interfaces/actionprops",
@@ -48,18 +44,18 @@ module.exports = {
4844
"api/interfaces/tabprops",
4945
"api/interfaces/textprops",
5046
"api/interfaces/viewprops",
51-
"api/interfaces/windowprops"
47+
"api/interfaces/windowprops",
5248
],
53-
"Classes": [
49+
Classes: [
5450
"api/classes/rnaction",
5551
"api/classes/rngridcolumn",
5652
"api/classes/rngridrow",
5753
"api/classes/rnmenu",
5854
"api/classes/rnmenubar",
59-
"api/classes/renderer"
60-
]
55+
"api/classes/renderer",
56+
],
6157
},
62-
"guides": {
58+
guides: {
6359
"The Basics": [
6460
"guides/getting-started",
6561
"guides/tutorial",
@@ -68,13 +64,14 @@ module.exports = {
6864
"guides/handle-events",
6965
"guides/scroll-view",
7066
"guides/images",
71-
"guides/networking"
67+
"guides/networking",
68+
"guides/packaging",
7269
],
73-
"Guides": [
70+
Guides: [
7471
"guides/debugging",
7572
"guides/debugging-in-vscode",
7673
"guides/using-native-node-modules",
77-
"guides/custom-nodegui-native-plugin"
78-
]
79-
}
80-
};
74+
"guides/custom-nodegui-native-plugin",
75+
],
76+
},
77+
};

0 commit comments

Comments
 (0)