File tree Expand file tree Collapse file tree 1 file changed +19
-12
lines changed
Expand file tree Collapse file tree 1 file changed +19
-12
lines changed Original file line number Diff line number Diff line change @@ -51,6 +51,24 @@ ${param.description}
5151 })`
5252 : "()" ) ;
5353
54+ const parametersTable = `
55+ <table>
56+ <thead>
57+ <tr>
58+ <th>name</th>
59+ <th>required</th>
60+ <th>description</th>
61+ </tr>
62+ </thead>
63+ <tbody>
64+ ${ parameterRows . join ( "\n" ) }
65+ </tbody>
66+ </table>` ;
67+
68+ const parameters = endpoint . parameters . length
69+ ? parametersTable
70+ : `This endpoint has no parameters` ;
71+
5472 const content = `
5573# ${ endpoint . name }
5674
@@ -66,18 +84,7 @@ ${example}
6684
6785## Parameters
6886
69- <table>
70- <thead>
71- <tr>
72- <th>name</th>
73- <th>required</th>
74- <th>description</th>
75- </tr>
76- </thead>
77- <tbody>
78- ${ parameterRows . join ( "\n" ) }
79- </tbody>
80- </table>
87+ ${ parameters }
8188
8289See also: [GitHub Developer Guide documentation](endpoint.documentationUrl).` ;
8390
You can’t perform that action at this time.
0 commit comments