4bnode 3.5.2 → 3.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +30 -30
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -12,95 +12,95 @@ npm install -g 4brains-node-generator
12
12
 
13
13
  ## Available Commands
14
14
 
15
- ### `node-app init <projectName>`
15
+ ### `4bnode init <projectName>`
16
16
 
17
17
  Initialize a new Node.js project with the specified name.
18
18
 
19
19
  ```sh
20
- node-app init my-project
20
+ 4bnode init my-project
21
21
  ```
22
22
 
23
- ### `node-app add-api <endpointName>`
23
+ ### `4bnode add-api <endpointName>`
24
24
 
25
25
  Add a new API endpoint to your project.
26
26
 
27
27
  ```sh
28
- node-app add-api users
28
+ 4bnode add-api users
29
29
  ```
30
30
 
31
- ### `node-app add-mongo`
31
+ ### `4bnode add-mongo`
32
32
 
33
33
  Integrate MongoDB into your project. This command sets up the necessary MongoDB configuration.
34
34
 
35
35
  ```sh
36
- node-app add-mongo
36
+ 4bnode add-mongo
37
37
  ```
38
38
 
39
- ### `node-app add-mongo-schema <schemaName>`
39
+ ### `4bnode add-mongo-schema <schemaName>`
40
40
 
41
41
  Create a new MongoDB schema. You will be prompted to enter field details for the schema.
42
42
 
43
43
  ```sh
44
- node-app add-mongo-schema User
44
+ 4bnode add-mongo-schema User
45
45
  ```
46
46
 
47
- ### `node-app add-login`
47
+ ### `4bnode add-login`
48
48
 
49
49
  Add a login template to an existing route in your project. You will be prompted to select a route and a model, and then enter the login fields.
50
50
 
51
51
  ```sh
52
- node-app add-login
52
+ 4bnode add-login
53
53
  ```
54
54
 
55
- ### `node-app add-mongo-insert`
55
+ ### `4bnode add-mongo-insert`
56
56
 
57
57
  Add a template for inserting data into a MongoDB collection. This command allows you to easily create routes for data insertion.
58
58
 
59
59
  ```sh
60
- node-app add-mongo-insert
60
+ 4bnode add-mongo-insert
61
61
  ```
62
62
 
63
- ### `node-app add-mongo-update`
63
+ ### `4bnode add-mongo-update`
64
64
 
65
65
  Add a template for updating data in a MongoDB collection. This facilitates creating routes for updating documents.
66
66
 
67
67
  ```sh
68
- node-app add-mongo-update
68
+ 4bnode add-mongo-update
69
69
  ```
70
70
 
71
- ### `node-app add-mongo-read`
71
+ ### `4bnode add-mongo-read`
72
72
 
73
73
  Add a template for reading data from a MongoDB collection, helping you to quickly set up read operations.
74
74
 
75
75
  ```sh
76
- node-app add-mongo-read
76
+ 4bnode add-mongo-read
77
77
  ```
78
78
 
79
- ### `node-app add-mongo-delete`
79
+ ### `4bnode add-mongo-delete`
80
80
 
81
81
  Add a template for deleting data from a MongoDB collection, making it easy to handle deletion operations.
82
82
 
83
83
  ```sh
84
- node-app add-mongo-delete
84
+ 4bnode add-mongo-delete
85
85
  ```
86
86
 
87
- ### `node-app add-socket`
87
+ ### `4bnode add-socket`
88
88
 
89
89
  Integrate Socket.io into your project for real-time communication capabilities.
90
90
 
91
91
  ```sh
92
- node-app add-socket
92
+ 4bnode add-socket
93
93
  ```
94
94
 
95
- ### `node-app add-websocket`
95
+ ### `4bnode add-websocket`
96
96
 
97
97
  Add native WebSocket support to your project.
98
98
 
99
99
  ```sh
100
- node-app add-websocket
100
+ 4bnode add-websocket
101
101
  ```
102
102
 
103
- ### `node-app add-serialport`
103
+ ### `4bnode add-serialport`
104
104
 
105
105
  Integrate SerialPort functionality into your project. This command does the following:
106
106
 
@@ -110,7 +110,7 @@ Integrate SerialPort functionality into your project. This command does the foll
110
110
  - Installs required dependencies: `serialport` and `@serialport/parser-readline`
111
111
 
112
112
  ```sh
113
- node-app add-serialport
113
+ 4bnode add-serialport
114
114
  ```
115
115
 
116
116
  Once added, your project will automatically initialize the serial port with the specified configuration and log incoming data.
@@ -128,7 +128,7 @@ Received data: <data from serial device>
128
128
  When you run the command to add a MongoDB schema, you will be prompted to enter the field details.
129
129
 
130
130
  ```sh
131
- node-app add-mongo-schema User
131
+ 4bnode add-mongo-schema User
132
132
  ```
133
133
 
134
134
  ### Adding a Login Template
@@ -136,7 +136,7 @@ node-app add-mongo-schema User
136
136
  When you run the command to add a login template, you will be prompted to select a route and a model, and then enter the login fields.
137
137
 
138
138
  ```sh
139
- node-app add-login
139
+ 4bnode add-login
140
140
  ```
141
141
 
142
142
  ## Real-time Communication Integration
@@ -146,7 +146,7 @@ node-app add-login
146
146
  When you add WebSocket integration, it will automatically be added to your project.
147
147
 
148
148
  ```sh
149
- node-app add-websocket
149
+ 4bnode add-websocket
150
150
  ```
151
151
 
152
152
  To use `req.wss` in your route endpoints, you can access the WebSocket server as follows:
@@ -167,7 +167,7 @@ router.get("/some-endpoint", (req, res) => {
167
167
  When you add Socket.io integration, it will automatically be added to your project.
168
168
 
169
169
  ```sh
170
- node-app add-socket
170
+ 4bnode add-socket
171
171
  ```
172
172
 
173
173
  To use `req.io` in your route endpoints, you can access the Socket.io server as follows:
@@ -190,8 +190,8 @@ Unknown command. Use -h or --help for help.
190
190
  You can also use `-h` or `--help` to get help information.
191
191
 
192
192
  ```sh
193
- node-app -h
194
- node-app --help
193
+ 4bnode -h
194
+ 4bnode --help
195
195
  ```
196
196
 
197
197
  ## License
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "4bnode",
3
- "version": "3.5.2",
3
+ "version": "3.5.3",
4
4
  "description": "A CLI tool to generate a Node.js app by 4Brains Technologies",
5
5
  "main": "index.js",
6
6
  "type": "module",