Skip to content

Commit df95114

Browse files
author
Alex Kras
committed
Fixes a bug with Node.js example generating invalid package.json and swagger.json
Currently string "... You can find out more about Swagger at <a href=\"http://swagger.io\">http://swagger.io</a> or ... " gets URL encoded, resuling in Node js throwing "Unable to parse" error. Use of {{{ }}} forces mustache to skip URL encoding http://mustache.github.io/mustache.5.html#Partials
1 parent b70f5bc commit df95114

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

modules/swagger-codegen/src/main/resources/nodejs/package.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "{{projectName}}",
33
"version": "{{appVersion}}",
4-
"description": "{{appDescription}}",
4+
"description": "{{{appDescription}}}",
55
"main": "index.js",
66
"keywords": [
77
"swagger"

modules/swagger-codegen/src/main/resources/nodejs/swagger.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"swagger": "2.0",
33
"info": {
44
"title": "{{appName}}",
5-
"description": "{{appDescription}}",
5+
"description": "{{{appDescription}}}",
66
"version": "{{apiVersion}}"
77
},
88
{{#apiInfo}}

0 commit comments

Comments
 (0)