1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Update editor options

http://expressjs.com/en/api.html#app.settings.table

Allow for setting individual options on the editor express app.  This app is not available through the embedded interface when using Node-RED within another application.

Update settings with editor options

Allow editor express app options to be set in settings.js

Update settings.js

formatting

Update settings.js

Co-Authored-By: TJKoury <TJKoury@gmail.com>

editorOptions -> httpServerOptions
This commit is contained in:
TJKoury 2018-10-04 10:17:04 -04:00 committed by Nick O'Leary
parent 7a9dd9ad9c
commit 8a68a3e861
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
2 changed files with 23 additions and 0 deletions

View File

@ -64,6 +64,11 @@ module.exports = {
}
});
}
if (settings.httpServerOptions) {
for (var eOption in settings.httpServerOptions) {
editorApp.set(eOption, settings.httpServerOptions[eOption]);
}
}
editorApp.get("/",ensureRuntimeStarted,ui.ensureSlash,ui.editor);
editorApp.get("/icons",needsPermission("nodes.read"),nodes.getIcons,apiUtil.errorHandler);

View File

@ -257,4 +257,22 @@ module.exports = {
enabled: false
}
},
// http://expressjs.com/en/api.html#app.settings.table
//httpServerOptions: {
// 'case sensitive routing': false,
// 'env': false,
// 'etag': false,
// 'jsonp callback name': false,
// 'json escape': false,
// 'json replacer': false,
// 'json spaces': false,
// 'query parser': false,
// 'strict routing': false,
// 'subdomain offset': false,
// 'trust proxy': false,
// 'views': false,
// 'view cache': false,
// 'view engine': false,
// 'x-powered-by': false
//}
}