feat: 文档整合scalar 主题, 优化 redoc-free主题, 优化页面渲染
This commit is contained in:
47
router/theme/scalar/api-reference.js
Normal file
47
router/theme/scalar/api-reference.js
Normal file
File diff suppressed because one or more lines are too long
27
router/theme/scalar/index.html
Normal file
27
router/theme/scalar/index.html
Normal file
@@ -0,0 +1,27 @@
|
||||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<title>{{DOC_TITLE}}</title>
|
||||
<meta charset="utf-8" />
|
||||
<meta
|
||||
content="width=device-width, initial-scale=1"
|
||||
name="viewport" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
|
||||
<!-- Load the Script -->
|
||||
<script src="api-reference.js"></script>
|
||||
|
||||
<!-- Initialize the Scalar API Reference -->
|
||||
<script>
|
||||
Scalar.createApiReference('#app', {
|
||||
// The URL of the OpenAPI/Swagger document
|
||||
url: '{{DOC_PATH}}',
|
||||
// Avoid CORS issues
|
||||
proxyUrl: '',
|
||||
})
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user