Open laurence-myers opened 3 years ago
e.g.
requestBody: content: application/json: schema: $ref: '#/components/schemas/foo-bar-baz'
The generate API files have code like this:
module.exports.do_foo = function do_foo (req, res, next) { var foo-bar-baz = req.swagger.params['foo-bar-baz'].value; // ... }
- is not a valid identifier character in JavaScript, because it's used as a mathematic operator foo - bar - baz.
-
foo - bar - baz
The identifier is also used in the generated impl/API service:
exports.do_foo = function(foo-bar-baz) { // ... }
Note: look at interaction of variableNamingConvention and modelPropertyNaming and see if one should affect parameter naming.
variableNamingConvention
modelPropertyNaming
e.g.
The generate API files have code like this:
-
is not a valid identifier character in JavaScript, because it's used as a mathematic operatorfoo - bar - baz
.The identifier is also used in the generated impl/API service: