You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -53,14 +53,15 @@ docker run -p 127.0.0.1:8080:8080 swagger-ui-builder
53
53
```
54
54
55
55
This will start Swagger UI at `http://localhost:8080`.
56
+
56
57
### Use
57
58
Once you open the Swagger UI, it will load the [Swagger Petstore](http://petstore.swagger.io/v2/swagger.json) service and show its APIs. You can enter your own server url and click explore to view the API.
58
59
59
60
### Customize
60
61
You may choose to customize Swagger UI for your organization. Here is an overview of whats in its various directories:
61
62
62
63
- dist: Contains a distribution which you can deploy on a server or load from your local machine.
63
-
- dist/lang: The swagger localisation
64
+
- dist/lang: The swagger localization
64
65
- lib: Contains javascript dependencies which swagger-ui depends on
65
66
- node_modules: Contains node modules which swagger-ui uses for its development.
66
67
- src
@@ -72,12 +73,12 @@ You may choose to customize Swagger UI for your organization. Here is an overvie
72
73
To use swagger-ui you should take a look at the [source of swagger-ui html page](https://github.com/swagger-api/swagger-ui/blob/master/dist/index.html) and customize it. This basically requires you to instantiate a SwaggerUi object and call load() on it as below:
73
74
74
75
```javascript
75
-
var swaggerUi =newSwaggerUi({
76
-
url:"http://petstore.swagger.io/v2/swagger.json",
77
-
dom_id:"swagger-ui-container"
78
-
});
76
+
var swaggerUi =newSwaggerUi({
77
+
url:"http://petstore.swagger.io/v2/swagger.json",
78
+
dom_id:"swagger-ui-container"
79
+
});
79
80
80
-
swaggerUi.load();
81
+
swaggerUi.load();
81
82
```
82
83
83
84
##### Parameters
@@ -147,8 +148,8 @@ To append new lexemex for translation you shoul do two things:
147
148
2. Mark this lexeme in source html with attribute data-sw-translate.
Copy file name to clipboardExpand all lines: test/specs/v1.2/petstore/api-docs.json
+1-1
Original file line number
Diff line number
Diff line change
@@ -53,7 +53,7 @@
53
53
"title": "Swagger Sample App",
54
54
"description": "This is a sample server Petstore server. You can find out more about Swagger \n at <a href=\"http://swagger.io\">http://swagger.io</a> or on irc.freenode.net, #swagger. For this sample,\n you can use the api key \"special-key\" to test the authorization filters",
0 commit comments