nextia 4.0.7 → 4.0.8
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.
- package/package.json +2 -2
- package/src/bin.js +7 -7
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nextia",
|
|
3
3
|
"description": "Create fast web applications",
|
|
4
|
-
"version": "4.0.
|
|
4
|
+
"version": "4.0.8",
|
|
5
5
|
"engines": {
|
|
6
6
|
"node": ">22"
|
|
7
7
|
},
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"clean": "rm -fr node_modules package-lock.json my-app",
|
|
33
33
|
"make": "npm run clean && npm install",
|
|
34
34
|
"lint": "standard 'src/**/*.{js,jsx}' 'test/**/*.{js,jsx}' --verbose",
|
|
35
|
-
"test:my-app": "node src/bin.js
|
|
35
|
+
"test:my-app": "node src/bin.js my-app"
|
|
36
36
|
},
|
|
37
37
|
"peerDependencies": {
|
|
38
38
|
"react": "^19.2.0",
|
package/src/bin.js
CHANGED
|
@@ -177,27 +177,27 @@ async function createProject (name) {
|
|
|
177
177
|
* main
|
|
178
178
|
*/
|
|
179
179
|
|
|
180
|
-
const
|
|
181
|
-
const
|
|
180
|
+
const ARG1 = process.argv[2]
|
|
181
|
+
const ARG2 = process.argv[3]
|
|
182
182
|
|
|
183
|
-
switch (
|
|
183
|
+
switch (ARG1) {
|
|
184
184
|
case 'page':
|
|
185
|
-
if (
|
|
185
|
+
if (ARG2) createPage(ARG2)
|
|
186
186
|
else console.warn('npm run page <page-name>')
|
|
187
187
|
break
|
|
188
188
|
|
|
189
189
|
case 'component':
|
|
190
|
-
if (
|
|
190
|
+
if (ARG2) createComponent(ARG2)
|
|
191
191
|
else console.warn('npm run component <ComponentName>')
|
|
192
192
|
break
|
|
193
193
|
|
|
194
194
|
case 'container':
|
|
195
|
-
if (
|
|
195
|
+
if (ARG2) createContainer(ARG2)
|
|
196
196
|
else console.warn('npm run container <ContainerName>')
|
|
197
197
|
break
|
|
198
198
|
|
|
199
199
|
default:
|
|
200
|
-
if (
|
|
200
|
+
if (ARG1) createProject(ARG1)
|
|
201
201
|
else console.warn('npm nextia@latest <ProjectName>')
|
|
202
202
|
break
|
|
203
203
|
}
|