-
Notifications
You must be signed in to change notification settings - Fork 296
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: added new option to group endpoints by path
- Loading branch information
Showing
29 changed files
with
1,826 additions
and
261 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, minimum-scale=1, initial-scale=1, user-scalable=yes"> | ||
<title>RapiDoc</title> | ||
</head> | ||
|
||
<body> | ||
<!-- | ||
Some sample spec to try | ||
https://api.apis.guru/v2/specs/stripe.com/2019-02-19/swagger.json | ||
https://api.apis.guru/v2/specs/github.com/v3/swagger.json | ||
https://api.apis.guru/v2/specs/bitbucket.org/2.0/swagger.json | ||
https://petstore.swagger.io/v2/swagger.json | ||
https://assets.zuora.com/zuora-documentation/swagger.yaml <<< Large spec with lot of markdown | ||
./specs/petstore_anyof.yaml <<< contains complex one-of with inline primitives and recursive objects | ||
./specs/oneof1.yaml <<< nested oneof | ||
--> | ||
<rapi-doc | ||
id="thedoc" | ||
spec-url="./specs/petstore_extended.yaml" | ||
theme="dark" | ||
allow-api-list-style-selection = "false" | ||
api-list-style = "group-by-path" | ||
> </rapi-doc> | ||
|
||
<!-- | ||
<script> | ||
document.addEventListener('DOMContentLoaded', (event) => { | ||
let docEl = document.getElementById("thedoc"); | ||
let strSpec = ` | ||
{ | ||
"swagger": "2.0", | ||
"info": { | ||
"description": "Sample to test" | ||
}, | ||
"paths": { | ||
"/pets": { | ||
"get": { | ||
"description": "Returns all pets from the system that the user has access to", | ||
"produces": [ "application/json"], | ||
"responses": { | ||
"200": { | ||
"description": "A list of pets.", | ||
"schema": { | ||
"type": "array", | ||
"items": { | ||
"$ref": "#/definitions/Pet" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"definitions": { | ||
"Pet": { | ||
"type": "object", | ||
"required": [ | ||
"id", | ||
"name" | ||
], | ||
"properties": { | ||
"id": { | ||
"type": "integer", | ||
"format": "int64" | ||
}, | ||
"name": { | ||
"type": "string" | ||
}, | ||
"tag": { | ||
"type": "string" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
`; | ||
let objSpec = JSON.parse(strSpec); | ||
docEl.loadSpec(objSpec); | ||
}) | ||
</script> | ||
--> | ||
|
||
<script type="text/javascript" src="rapidoc-min.js"></script></body> | ||
|
||
</html> |
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<!doctype html> | ||
<head> | ||
<!-- Global site tag (gtag.js) - Google Analytics --> | ||
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-132775238-1"></script> | ||
<script> | ||
window.dataLayer = window.dataLayer || []; | ||
function gtag(){dataLayer.push(arguments);} | ||
gtag('js', new Date()); | ||
|
||
gtag('config', 'UA-132775238-1'); | ||
</script> | ||
|
||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, minimum-scale=1, initial-scale=1, user-scalable=yes"> | ||
<script type="text/javascript" src="../rapidoc-min.js"></script> | ||
<style> | ||
rapi-doc{ | ||
width:100%; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<rapi-doc spec-url="../specs/bitbucket.json" style="min-width:460px" api-list-style="group-by-path"> </rapi-doc> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.