fix(oas31): fix re-rendering of the Webhooks component (#9938)

Refs #9937
This commit is contained in:
Oliwia Rogala
2024-05-15 13:52:41 +02:00
committed by GitHub
parent 6d2b88eb43
commit b5c84f44c7
4 changed files with 97 additions and 2 deletions

View File

@@ -3,6 +3,7 @@
*/
import React from "react"
import PropTypes from "prop-types"
import { List } from "immutable"
const Webhooks = ({ specSelectors, getComponent }) => {
const operationDTOs = specSelectors.selectWebhooksOperations()
@@ -25,7 +26,7 @@ const Webhooks = ({ specSelectors, getComponent }) => {
tag="webhooks"
method={operationDTO.method}
path={pathItemName}
specPath={operationDTO.specPath}
specPath={List(operationDTO.specPath)}
allowTryItOut={false}
/>
))}

View File

@@ -42,7 +42,7 @@ export const selectWebhooksOperations = createSelector(
operation: Map({ operation }),
method,
path: pathItemName,
specPath: List(["webhooks", pathItemName, method]),
specPath: ["webhooks", pathItemName, method],
}))
return allOperations.concat(pathItemOperations)