MCPcopy
hub / github.com/swagger-api/swagger-ui / getExtensions

Function getExtensions

src/core/utils/index.js:710–715  ·  view source on GitHub ↗
(defObj)

Source from the content-addressed store, hash-verified

708}
709
710export const getExtensions = (defObj) => {
711 if(Map.isMap(defObj)) {
712 return defObj.filter((v, k) => isExtension(k))
713 }
714 return Object.keys(defObj).filter((key) => isExtension(key))
715}
716export const getCommonExtensions = (defObj) => defObj.filter((v, k) => /^pattern|maxLength|minLength|maximum|minimum/.test(k))
717
718// Deeply strips a specific key from an object.

Callers 9

utils.jsFile · 0.90
renderMethod · 0.90
renderMethod · 0.90
renderMethod · 0.90
renderMethod · 0.90
renderMethod · 0.90
ExternalDocsFunction · 0.90
XmlFunction · 0.90
DiscriminatorFunction · 0.90

Calls 1

isExtensionFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…