generator-nitro 11.0.3 → 11.0.5
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/generators/app/templates/CUTAWAYpackage.json +5 -5
- package/generators/app/templates/config/custom-environment-variables.js +1 -0
- package/generators/app/templates/config/default.js +1 -0
- package/generators/app/templates/project/docs/nitro-config.md +18 -7
- package/generators/app/templates/project/docs/nitro-themes.md +1 -1
- package/generators/server/templates/package.json +1 -1
- package/package.json +3 -3
- package/readme.md +2 -2
|
@@ -65,8 +65,8 @@
|
|
|
65
65
|
"prod:build": "npm run build",
|
|
66
66
|
"prod:serve": "cross-env NODE_ENV=production nitro-app-serve",<% if (options.themes) { %>
|
|
67
67
|
"start": "npm run start:light",
|
|
68
|
-
"start:light": "cross-env THEME=light PORT=8080 npm run dev",
|
|
69
|
-
"start:dark": "cross-env THEME=dark PORT=8081 npm run dev"<% } else { %>
|
|
68
|
+
"start:light": "cross-env THEME=light PORT=8080 HMR_PORT=3000 npm run dev",
|
|
69
|
+
"start:dark": "cross-env THEME=dark PORT=8081 HMR_PORT=3001 npm run dev"<% } else { %>
|
|
70
70
|
"start": "npm run dev"<% } %>
|
|
71
71
|
},
|
|
72
72
|
"keywords": [
|
|
@@ -120,14 +120,14 @@
|
|
|
120
120
|
"husky": "9.1.7",
|
|
121
121
|
"license-checker": "25.0.1",
|
|
122
122
|
"lighthouse": "13.0.3",
|
|
123
|
-
"lint-staged": "16.2
|
|
124
|
-
"npm-check-updates": "19.
|
|
123
|
+
"lint-staged": "16.3.2",
|
|
124
|
+
"npm-check-updates": "19.6.3",
|
|
125
125
|
"npm-run-all": "4.1.5",
|
|
126
126
|
"prettier": "3.8.1",
|
|
127
127
|
"rimraf": "6.1.3",
|
|
128
128
|
"stylelint": "16.26.1",<% if (options.jsCompiler === 'ts') { %>
|
|
129
129
|
"typescript": "5.9.3",<% } %>
|
|
130
|
-
"webpack": "5.105.
|
|
130
|
+
"webpack": "5.105.4",
|
|
131
131
|
"webpack-cli": "6.0.1",
|
|
132
132
|
"yo": "6.0.0"
|
|
133
133
|
},
|
|
@@ -114,15 +114,16 @@ The millisecond 'delay' between a file change and task execution.
|
|
|
114
114
|
- Default: 8080
|
|
115
115
|
|
|
116
116
|
The express server runs on this port.
|
|
117
|
-
An environment variable PORT will overwrite this property.
|
|
117
|
+
An environment variable `PORT` will overwrite this property.
|
|
118
118
|
|
|
119
|
-
|
|
119
|
+
### `server.hmrPort`
|
|
120
120
|
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
121
|
+
- Type: Integer
|
|
122
|
+
- Default: 3000
|
|
123
|
+
|
|
124
|
+
The hot module reload feature runs on this port in development environments.
|
|
125
|
+
|
|
126
|
+
An environment variable `HMR_PORT` will overwrite this property.
|
|
126
127
|
|
|
127
128
|
### `server.host`
|
|
128
129
|
|
|
@@ -146,6 +147,16 @@ If set to `true`, all requests through express will be compressed.
|
|
|
146
147
|
If set to `true`, viewData is processed before all routes.
|
|
147
148
|
For backwards compatibility, you can set it to `false`, to get the loading behavior before Nitro version 9.
|
|
148
149
|
|
|
150
|
+
#### Example config
|
|
151
|
+
|
|
152
|
+
```
|
|
153
|
+
server: {
|
|
154
|
+
port: 8080,
|
|
155
|
+
hmrPort: 3000,
|
|
156
|
+
host: 'dev.local',
|
|
157
|
+
}
|
|
158
|
+
```
|
|
159
|
+
|
|
149
160
|
## Gulp
|
|
150
161
|
|
|
151
162
|
### `gulp.dumpViews`
|
|
@@ -88,7 +88,7 @@ Run modes and build tasks are configured in 'package.json'
|
|
|
88
88
|
For development mode you need a start script for each theme:
|
|
89
89
|
|
|
90
90
|
```
|
|
91
|
-
"start:<theme-id>": "cross-env THEME=<theme-id> PORT=8081 npm run dev",
|
|
91
|
+
"start:<theme-id>": "cross-env THEME=<theme-id> PORT=8081 HMR_PORT=3000 npm run dev",
|
|
92
92
|
```
|
|
93
93
|
|
|
94
94
|
Use different ports for each theme to be able to run them in parallel.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "generator-nitro",
|
|
3
|
-
"version": "11.0.
|
|
3
|
+
"version": "11.0.5",
|
|
4
4
|
"description": "Yeoman generator for the nitro frontend framework",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -50,9 +50,9 @@
|
|
|
50
50
|
"@merkle-open/eslint-config": "4.0.1",
|
|
51
51
|
"eslint": "8.57.1",
|
|
52
52
|
"eslint-plugin-import": "2.32.0",
|
|
53
|
-
"fs-extra": "11.3.
|
|
53
|
+
"fs-extra": "11.3.4",
|
|
54
54
|
"mocha": "11.7.5",
|
|
55
55
|
"yeoman-assert": "3.1.1",
|
|
56
|
-
"yeoman-test": "11.
|
|
56
|
+
"yeoman-test": "11.3.1"
|
|
57
57
|
}
|
|
58
58
|
}
|
package/readme.md
CHANGED
|
@@ -64,7 +64,7 @@ On creating a new project, you will be guided through some configuration options
|
|
|
64
64
|
- Using theming feature `--themes` (default: false)
|
|
65
65
|
- Using client side templates `--clientTpl` (default: false)
|
|
66
66
|
- Including example code `--exampleCode` (default: false)
|
|
67
|
-
- Installing nitro-exporter
|
|
67
|
+
- Installing nitro-exporter `--exporter` (default: false)
|
|
68
68
|
|
|
69
69
|
It's possible to pass in these options through the command line:
|
|
70
70
|
|
|
@@ -98,7 +98,7 @@ Note: Generators are to be run from the root directory of your project.
|
|
|
98
98
|
## Generated app
|
|
99
99
|
|
|
100
100
|
Have a look at the [sample project](https://nitro-project-test.netlify.app/)
|
|
101
|
-
which contains the examples of a generated project and was statified with the default configuration of the
|
|
101
|
+
which contains the examples of a generated project and was statified with the default configuration of the nitro-exporter.
|
|
102
102
|
|
|
103
103
|
See how to use the [generated app](https://github.com/merkle-open/generator-nitro/blob/master/packages/project-nitro/project/docs/nitro.md)
|
|
104
104
|
|