main
Last change
on this file was d24f17c, checked in by Aleksandar Panovski <apano77@…>, 15 months ago |
Initial commit
|
-
Property mode
set to
100644
|
File size:
500 bytes
|
Rev | Line | |
---|
[d24f17c] | 1 | import resolveOpenAPI31Strategy from './resolve.js';
|
---|
| 2 | import normalize, { pojoAdapter } from './normalize.js';
|
---|
| 3 | import { isOpenAPI31 } from '../../../helpers/openapi-predicates.js';
|
---|
| 4 | const openApi31ApiDOMStrategy = {
|
---|
| 5 | name: 'openapi-3-1-apidom',
|
---|
| 6 | match({
|
---|
| 7 | spec
|
---|
| 8 | }) {
|
---|
| 9 | return isOpenAPI31(spec);
|
---|
| 10 | },
|
---|
| 11 | normalize({
|
---|
| 12 | spec
|
---|
| 13 | }) {
|
---|
| 14 | return pojoAdapter(normalize)(spec);
|
---|
| 15 | },
|
---|
| 16 | async resolve(options) {
|
---|
| 17 | return resolveOpenAPI31Strategy(options);
|
---|
| 18 | }
|
---|
| 19 | };
|
---|
| 20 | export default openApi31ApiDOMStrategy; |
---|
Note:
See
TracBrowser
for help on using the repository browser.