fix(swagger-ui-react): fix prop type for plugins (#7877)

Co-authored-by: Tim Lai <timothy.lai@gmail.com>
This commit is contained in:
Airam
2022-03-02 20:15:44 +01:00
committed by GitHub
parent eece9f5d9b
commit 544d16da35

View File

@@ -106,7 +106,10 @@ SwaggerUI.propTypes = {
PropTypes.oneOf(["get", "put", "post", "delete", "options", "head", "patch", "trace"])
),
queryConfigEnabled: PropTypes.bool,
plugins: PropTypes.arrayOf(PropTypes.object),
plugins: PropTypes.oneOfType([
PropTypes.arrayOf(PropTypes.object),
PropTypes.func,
]),
displayOperationId: PropTypes.bool,
showMutatedRequest: PropTypes.bool,
defaultModelExpandDepth: PropTypes.number,