Commit Graph

42 Commits

Author SHA1 Message Date
Damien
516e666f1c feat(wrapComponents): new chain configuration option (#7236)
This commit provides a backward compatible mechanism to chain wrap 
an individual component multiple times

`Chain` mode: allow chaining of plugins on a given component
`Legacy` mode: last plugin to wrap a given component will supercede others

* chore: Add unit test for wrapComponent wrapping

* doc: Add documentation about the new pluginsOptions configuration

* doc: Add a sidenote on plugin-api page

Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2021-05-20 15:41:11 -07:00
Tim Lai
2373a83fe2 feat: remove node_native option from request snippets plugin (#7181)
* snippet generator support intended for different shell options only
* will not maintain snippet generator for various languages
2021-04-14 10:55:31 -07:00
Mahtis Michel
8405fa0101 feat: request snippets plugin (#6910) 2021-03-10 11:02:34 -08:00
Kyle Hoskins
265bdc07b7 feat: add tryItOutEnabled configuration (#6865)
* feat: add tryItOutEnabled configuration

allow users to set tryItOutEnabled: true to display
the "Try it out" section by default

tryItOutEnabled to take === "true" for the
query string value or === true if someone
implements query string type parsing in the query
2021-01-26 09:00:38 -08:00
Amir Bitaraf Haghighi
a7ba55ad03 feat(docker): add docker support for persist authorization variable (#6832) 2021-01-13 13:23:44 -08:00
Shelby Sanders
6a4e52aadb feat: support for showExtensions on Response objects (#6535) 2020-10-21 18:49:39 -07:00
Mahtis Michel
deeff4b42c docs(docker): add docker-compose env file configuration example (#6465) 2020-10-07 16:33:55 -07:00
Adam David
cbe99c8c1a feat(curl): configuration setting to pass additional options to curl command for "Try it out" (#6288)
Allows `requestInterceptor` to add options to the curl command.
For example:

```js
requestInterceptor: function (request) {
  if (request.method === 'GET') {
    request.curlOptions = ['-g']
    request.url = request.url
      .replace('%5B', '[')
      .replace('%5D', ']')
      .replace('%2C', ',');
  }
  return request;
}
```
2020-09-22 11:14:51 -07:00
Amir Bitaraf Haghighi
96aecc8860 feat: Preserve authorization on browser refresh and close/reopen (#5939)
* Add default configuration `preserveAuthorization`

* Add localStorage to auth plugin

* Add persistAuthorization unit tests

* Refactor persistAuthorization to use wrapped actions

* Upgrade unit tests to be compatible with jest

* Add persistAuthorization documentation


Co-authored-by: Tim Lai <timothy.lai@gmail.com>
2020-09-11 14:05:37 -07:00
Helen Kosova
887563ab79 docs: Improve descriptions of syntaxHighlight parameters (#6242) 2020-07-28 16:46:25 -07:00
Tim Lai
a73783b73d feat: syntax highlighting of code section (#6236)
Co-authored-by: AdrieanKhisbe <adriean.khisbe@live.fr>
2020-07-17 15:29:15 -07:00
Vladimir Gorej
a616cb471d fix(Markdown): render markdown in more secure way
This commit changes markdown sanitization behaviour in following way:

class, style and data-* attributes are removed by default. These attributes
open possible vulnerability vectors to attackers.

The original behavior of sanitizer (before this commit) can be enabled by *useUnsafeMarkdown* configuration option.
Use this configuration option with caution and only in cases when you know
what you're doing.
2020-06-11 21:51:15 +02:00
Wesley Schwengle
117dcc9b16 Disable the validation badge for those who do not want it (#5994)
* disabled on string values: "127.0.0.1", "localhost", "none"
2020-06-10 15:31:35 -07:00
kyle
8cabcffddf housekeeping: document Docker OAUTH2_REDIRECT_URL option (#5641) 2019-10-02 20:23:05 -07:00
kyle
94c86d3d50 improvement: online.swagger.io -> validator.swagger.io (#5599) 2019-09-09 21:33:23 -07:00
Helen Kosova
43db164a91 docs: clarify that preauthorizeApiKey works for OAS3 Bearer auth too (via #5566) 2019-08-26 16:09:05 -07:00
Helen Kosova
8822a7229a Change Swagger-UI -> Swagger UI in docs (#5479)
* Change Swagger-UI -> Swagger UI in docs

* Changed back to SwaggerUI in places that refer to JS construct
2019-07-19 09:22:45 -06:00
Segev Finer
be72c292ca feature: add withCredentials configuration key (via #5149)
* Add the withCredentials configuration key

It enables passing credentials in CORS requests. e.g. Cookies and
Authorization headers.

* Improve withCredentials documentation

* Add unit tests for the withCredentials config

* Update configuration.md

* Update configuration.md

* only set `withCredentials` Fetch flag if the config value is truthy

there are some workarounds in the wild today that involve setting `withCredentials` on `system.fn.fetch` directly. 

this approach avoids mangling those existing workarounds!

* add more test cases

* Update configs-wrap-actions.js

* Update index.js
2019-03-20 12:36:08 -07:00
kyle
5052f37909 housekeeping: fix typo in configuration anchor name (via #5109) 2019-01-05 00:57:54 -06:00
kyle
c6eb8edb5f feature: Docker OAuth block support (via #4987)
* add `onFound` callback to schemas
* add warning to method docs (for #4957)
* implement Docker OAuth2 init block support
* update docs
* add OAUTH_SCOPE_SEPARATOR
* drop OAuth env from Dockerfile and run script
* don't indent the first oauth block line
* drop unused `dedent` import
* touch up warning message
* add more test cases
* return an empty block if no OAuth content is generated
* fix broken doc line
2018-11-01 18:52:13 -04:00
kyle
31a8b13777 feature: full-spectrum runtime Docker configuration (via #4965)
* reorganize docker things

* Configurator WIP

* implement Docker runtime config generator

* add tests

* update documentation

* fix Markdown tables

* Move Docker section

* add note to README

* move up `nodejs` install for more aggressive caching

* drop exclusive test

* fix missing `DISPLAY_OPERATION_ID`
2018-11-01 14:53:29 -04:00
Ron
59a6a9b20f Added anchors to configuration parameters (#4711)
This allows referencing a configuration parameter directly when responding to tickets or from within the documentation.
2018-07-11 13:04:56 -05:00
Brett Randall
073b1df730 Updated 'urls' (An array of API definition objects) description. (#4525)
* Updated 'urls' (An array of API definition objects) description.

Updated 'urls' (An array of API definition objects) description to show an actual object array containing two (2) urls, clarifying this configuration-option.

* urls is an array, not a string
2018-05-07 21:56:08 -07:00
Helder Sepulveda
cbff0251ae feat: option to show common query parameters (#4245)
* extend getExtensions

Add optional param to getExtensions that can retrieve more stuff

* Add getCommonExtensions

* Trim trailing spaces

* Remove unused parameter

* Move the format inline with the param type

* correction to UnitTest
2018-04-26 21:18:45 -07:00
kyle
911a140e38 docs: add async interceptor documentation (#4418)
* docs: add async interceptor documentation

* Update configuration.md
2018-04-06 15:19:44 -07:00
kyle
b8cf080e6c docs: fix broken method table (#4340) 2018-03-16 22:34:54 -07:00
kyle
245428e7cd feat: preauthorization (#4339)
* feat: swagger 2.0 preauthorization methods
* tests: add cases for oas3 preauthorization
* docs: add new preauth docs; touch up existing auth docs
* tests: add `rootInject` tests
* docs: remove unfinished sentence
2018-03-16 22:25:04 -07:00
kyle
624a81201f feat: onComplete config option (#4322)
* feat: `onComplete` config option

* tests(e2e): add case for onComplete option
2018-03-16 00:08:39 -07:00
Scott O'Hara
f589cb99af feature: supportedSubmitMethods config parameter (#4186) 2018-02-09 19:39:43 -08:00
HelderSepu
28c706c70a Add defaultModelsExpandDepth
This change separates:
the Model (the one on the model-example section)
from
the Models (the ones at the bottom)
2017-12-08 21:12:41 -05:00
Abner Chen
112bca9065 fix link 2017-12-08 00:00:04 +08:00
Kyle Shockey
c68d1589ff Prepare revised documentation for merge 2017-12-05 18:46:10 -08:00
Kyle Shockey
55622b6105 Add required parameters 2017-12-05 15:24:19 -08:00
Kyle Shockey
1b926d834f Sort parameters alphabetically 2017-12-05 15:22:37 -08:00
Kyle Shockey
8a8ddd7c51 Touch up configuration docs 2017-12-05 15:17:01 -08:00
Kyle Shockey
ba605eb2ed Fix filter markdown 2017-12-05 15:14:49 -08:00
Kyle Shockey
07dac1b582 Add parameter type information 2017-12-05 15:13:19 -08:00
Kyle Shockey
2eba306698 Add plugin system documentation 2017-12-05 14:49:08 -08:00
Kyle Shockey
b7f4b23025 Segment configuration document 2017-12-05 14:44:37 -08:00
Kyle Shockey
84f4ec805e Reshuffle more documentation locations 2017-12-04 22:58:58 -08:00
Kyle Shockey
9400c91820 Merge branch 'master' of github.com:swagger-api/swagger-ui into ft/docs 2017-12-04 20:38:09 -08:00
Kyle Shockey
f6206d35fd Docs WIP 2017-10-04 18:39:13 -07:00