@redocly/openapi-core 0.0.0-snapshot.1744362365 → 0.0.0-snapshot.1744801622
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/benchmark/benches/lint-with-many-rules.bench.d.ts +1 -2
- package/lib/benchmark/benches/lint-with-many-rules.bench.js +19 -17
- package/lib/benchmark/benches/lint-with-nested-rule.bench.d.ts +1 -2
- package/lib/benchmark/benches/lint-with-nested-rule.bench.js +19 -15
- package/lib/benchmark/benches/lint-with-no-rules.bench.d.ts +1 -2
- package/lib/benchmark/benches/lint-with-no-rules.bench.js +19 -15
- package/lib/benchmark/benches/lint-with-top-level-rule-report.bench.d.ts +1 -2
- package/lib/benchmark/benches/lint-with-top-level-rule-report.bench.js +19 -15
- package/lib/benchmark/benches/lint-with-top-level-rule.bench.d.ts +1 -2
- package/lib/benchmark/benches/lint-with-top-level-rule.bench.js +19 -15
- package/lib/benchmark/benches/recommended-oas3.bench.d.ts +1 -2
- package/lib/benchmark/benches/recommended-oas3.bench.js +18 -15
- package/lib/benchmark/benches/resolve-with-no-external.bench.d.ts +1 -2
- package/lib/benchmark/benches/resolve-with-no-external.bench.js +17 -14
- package/lib/benchmark/utils.d.ts +4 -5
- package/lib/benchmark/utils.js +14 -11
- package/lib/bundle.d.ts +9 -8
- package/lib/bundle.js +84 -72
- package/lib/config/all.d.ts +1 -2
- package/lib/config/all.js +3 -2
- package/lib/config/builtIn.d.ts +1 -2
- package/lib/config/builtIn.js +49 -44
- package/lib/config/config-resolvers.d.ts +5 -6
- package/lib/config/config-resolvers.js +94 -85
- package/lib/config/config.d.ts +8 -6
- package/lib/config/config.js +73 -66
- package/lib/config/index.d.ts +7 -8
- package/lib/config/index.js +23 -8
- package/lib/config/load.d.ts +8 -5
- package/lib/config/load.js +73 -28
- package/lib/config/minimal.d.ts +1 -2
- package/lib/config/minimal.js +3 -2
- package/lib/config/recommended-strict.d.ts +1 -2
- package/lib/config/recommended-strict.js +3 -2
- package/lib/config/recommended.d.ts +1 -2
- package/lib/config/recommended.js +3 -2
- package/lib/config/rules.d.ts +3 -4
- package/lib/config/rules.js +6 -4
- package/lib/config/spec.d.ts +1 -2
- package/lib/config/spec.js +3 -2
- package/lib/config/types.d.ts +13 -6
- package/lib/config/types.js +2 -2
- package/lib/config/utils.d.ts +2 -3
- package/lib/config/utils.js +89 -75
- package/lib/decorators/arazzo/index.d.ts +0 -1
- package/lib/decorators/arazzo/index.js +4 -2
- package/lib/decorators/async2/index.d.ts +0 -1
- package/lib/decorators/async2/index.js +4 -2
- package/lib/decorators/async3/index.d.ts +0 -1
- package/lib/decorators/async3/index.js +4 -2
- package/lib/decorators/common/filters/filter-helper.d.ts +1 -2
- package/lib/decorators/common/filters/filter-helper.js +12 -9
- package/lib/decorators/common/filters/filter-in.d.ts +1 -2
- package/lib/decorators/common/filters/filter-in.js +8 -5
- package/lib/decorators/common/filters/filter-out.d.ts +1 -2
- package/lib/decorators/common/filters/filter-out.js +8 -5
- package/lib/decorators/common/info-description-override.d.ts +1 -2
- package/lib/decorators/common/info-description-override.js +7 -4
- package/lib/decorators/common/info-override.d.ts +1 -2
- package/lib/decorators/common/info-override.js +5 -2
- package/lib/decorators/common/media-type-examples-override.d.ts +1 -2
- package/lib/decorators/common/media-type-examples-override.js +10 -7
- package/lib/decorators/common/operation-description-override.d.ts +1 -2
- package/lib/decorators/common/operation-description-override.js +7 -4
- package/lib/decorators/common/registry-dependencies.d.ts +2 -0
- package/lib/decorators/common/registry-dependencies.js +24 -0
- package/lib/decorators/common/remove-x-internal.d.ts +1 -2
- package/lib/decorators/common/remove-x-internal.js +14 -11
- package/lib/decorators/common/tag-description-override.d.ts +1 -2
- package/lib/decorators/common/tag-description-override.js +7 -4
- package/lib/decorators/oas2/index.d.ts +2 -2
- package/lib/decorators/oas2/index.js +20 -16
- package/lib/decorators/oas2/remove-unused-components.d.ts +1 -2
- package/lib/decorators/oas2/remove-unused-components.js +7 -4
- package/lib/decorators/oas3/index.d.ts +2 -2
- package/lib/decorators/oas3/index.js +22 -18
- package/lib/decorators/oas3/remove-unused-components.d.ts +1 -2
- package/lib/decorators/oas3/remove-unused-components.js +8 -5
- package/lib/decorators/overlay1/index.d.ts +0 -1
- package/lib/decorators/overlay1/index.js +4 -2
- package/lib/env.d.ts +0 -1
- package/lib/env.js +5 -3
- package/lib/format/codeframes.d.ts +1 -2
- package/lib/format/codeframes.js +19 -15
- package/lib/format/format.d.ts +1 -2
- package/lib/format/format.js +62 -57
- package/lib/index.d.ts +26 -29
- package/lib/index.js +98 -24
- package/lib/js-yaml/index.d.ts +0 -1
- package/lib/js-yaml/index.js +11 -7
- package/lib/lint.d.ts +10 -11
- package/lib/lint.js +44 -39
- package/lib/logger.d.ts +1 -2
- package/lib/logger.js +17 -15
- package/lib/oas-types.d.ts +3 -4
- package/lib/oas-types.js +32 -27
- package/lib/output.d.ts +3 -0
- package/lib/output.js +9 -0
- package/lib/redocly/domains.d.ts +14 -0
- package/lib/redocly/domains.js +41 -0
- package/lib/redocly/index.d.ts +30 -0
- package/lib/redocly/index.js +131 -0
- package/lib/redocly/redocly-client-types.d.ts +8 -0
- package/lib/redocly/redocly-client-types.js +2 -0
- package/lib/redocly/registry-api-types.d.ts +29 -0
- package/lib/redocly/registry-api-types.js +2 -0
- package/lib/redocly/registry-api.d.ts +17 -0
- package/lib/redocly/registry-api.js +100 -0
- package/lib/ref-utils.d.ts +2 -3
- package/lib/ref-utils.js +33 -18
- package/lib/resolve.d.ts +2 -3
- package/lib/resolve.js +45 -36
- package/lib/rules/ajv.d.ts +3 -4
- package/lib/rules/ajv.js +10 -7
- package/lib/rules/arazzo/criteria-unique.d.ts +1 -2
- package/lib/rules/arazzo/criteria-unique.js +5 -2
- package/lib/rules/arazzo/index.d.ts +1 -2
- package/lib/rules/arazzo/index.js +35 -33
- package/lib/rules/arazzo/parameters-unique.d.ts +1 -2
- package/lib/rules/arazzo/parameters-unique.js +5 -2
- package/lib/rules/arazzo/requestBody-replacements-unique.d.ts +1 -2
- package/lib/rules/arazzo/requestBody-replacements-unique.js +5 -2
- package/lib/rules/arazzo/sourceDescription-type.d.ts +1 -2
- package/lib/rules/arazzo/sourceDescription-type.js +5 -2
- package/lib/rules/arazzo/sourceDescriptions-name-unique.d.ts +1 -2
- package/lib/rules/arazzo/sourceDescriptions-name-unique.js +5 -2
- package/lib/rules/arazzo/sourceDescriptions-not-empty.d.ts +1 -2
- package/lib/rules/arazzo/sourceDescriptions-not-empty.js +5 -2
- package/lib/rules/arazzo/step-onFailure-unique.d.ts +1 -2
- package/lib/rules/arazzo/step-onFailure-unique.js +5 -2
- package/lib/rules/arazzo/step-onSuccess-unique.d.ts +1 -2
- package/lib/rules/arazzo/step-onSuccess-unique.js +5 -2
- package/lib/rules/arazzo/stepId-unique.d.ts +1 -2
- package/lib/rules/arazzo/stepId-unique.js +5 -2
- package/lib/rules/arazzo/workflow-dependsOn.d.ts +1 -2
- package/lib/rules/arazzo/workflow-dependsOn.js +5 -2
- package/lib/rules/arazzo/workflowId-unique.d.ts +1 -2
- package/lib/rules/arazzo/workflowId-unique.js +5 -2
- package/lib/rules/async2/channels-kebab-case.d.ts +1 -2
- package/lib/rules/async2/channels-kebab-case.js +5 -2
- package/lib/rules/async2/index.d.ts +1 -2
- package/lib/rules/async2/index.js +24 -22
- package/lib/rules/async2/no-channel-trailing-slash.d.ts +1 -2
- package/lib/rules/async2/no-channel-trailing-slash.js +5 -2
- package/lib/rules/async3/channels-kebab-case.d.ts +1 -2
- package/lib/rules/async3/channels-kebab-case.js +5 -2
- package/lib/rules/async3/index.d.ts +1 -2
- package/lib/rules/async3/index.js +24 -22
- package/lib/rules/async3/no-channel-trailing-slash.d.ts +1 -2
- package/lib/rules/async3/no-channel-trailing-slash.js +6 -3
- package/lib/rules/common/assertions/asserts.d.ts +2 -3
- package/lib/rules/common/assertions/asserts.js +38 -35
- package/lib/rules/common/assertions/index.d.ts +3 -4
- package/lib/rules/common/assertions/index.js +10 -7
- package/lib/rules/common/assertions/utils.d.ts +4 -5
- package/lib/rules/common/assertions/utils.js +29 -21
- package/lib/rules/common/info-contact.d.ts +1 -2
- package/lib/rules/common/info-contact.js +7 -4
- package/lib/rules/common/info-license-strict.d.ts +1 -2
- package/lib/rules/common/info-license-strict.js +10 -7
- package/lib/rules/common/info-license-url.d.ts +1 -2
- package/lib/rules/common/info-license-url.js +7 -4
- package/lib/rules/common/info-license.d.ts +1 -2
- package/lib/rules/common/info-license.js +7 -4
- package/lib/rules/common/no-ambiguous-paths.d.ts +1 -2
- package/lib/rules/common/no-ambiguous-paths.js +5 -2
- package/lib/rules/common/no-enum-type-mismatch.d.ts +1 -2
- package/lib/rules/common/no-enum-type-mismatch.js +9 -6
- package/lib/rules/common/no-http-verbs-in-paths.d.ts +1 -2
- package/lib/rules/common/no-http-verbs-in-paths.js +8 -5
- package/lib/rules/common/no-identical-paths.d.ts +1 -2
- package/lib/rules/common/no-identical-paths.js +5 -2
- package/lib/rules/common/no-invalid-parameter-examples.d.ts +0 -1
- package/lib/rules/common/no-invalid-parameter-examples.js +9 -6
- package/lib/rules/common/no-invalid-schema-examples.d.ts +1 -2
- package/lib/rules/common/no-invalid-schema-examples.js +9 -6
- package/lib/rules/common/no-path-trailing-slash.d.ts +1 -2
- package/lib/rules/common/no-path-trailing-slash.js +5 -2
- package/lib/rules/common/no-required-schema-properties-undefined.d.ts +1 -2
- package/lib/rules/common/no-required-schema-properties-undefined.js +7 -4
- package/lib/rules/common/no-schema-type-mismatch.d.ts +1 -2
- package/lib/rules/common/no-schema-type-mismatch.js +5 -2
- package/lib/rules/common/operation-2xx-response.d.ts +1 -2
- package/lib/rules/common/operation-2xx-response.js +8 -5
- package/lib/rules/common/operation-4xx-response.d.ts +1 -2
- package/lib/rules/common/operation-4xx-response.js +8 -5
- package/lib/rules/common/operation-description.d.ts +1 -2
- package/lib/rules/common/operation-description.js +7 -4
- package/lib/rules/common/operation-operationId-unique.d.ts +1 -2
- package/lib/rules/common/operation-operationId-unique.js +5 -2
- package/lib/rules/common/operation-operationId-url-safe.d.ts +1 -2
- package/lib/rules/common/operation-operationId-url-safe.js +5 -2
- package/lib/rules/common/operation-operationId.d.ts +1 -2
- package/lib/rules/common/operation-operationId.js +7 -4
- package/lib/rules/common/operation-parameters-unique.d.ts +1 -2
- package/lib/rules/common/operation-parameters-unique.js +5 -2
- package/lib/rules/common/operation-singular-tag.d.ts +1 -2
- package/lib/rules/common/operation-singular-tag.js +5 -2
- package/lib/rules/common/operation-summary.d.ts +1 -2
- package/lib/rules/common/operation-summary.js +7 -4
- package/lib/rules/common/operation-tag-defined.d.ts +1 -2
- package/lib/rules/common/operation-tag-defined.js +5 -2
- package/lib/rules/common/parameter-description.d.ts +1 -2
- package/lib/rules/common/parameter-description.js +5 -2
- package/lib/rules/common/path-declaration-must-exist.d.ts +1 -2
- package/lib/rules/common/path-declaration-must-exist.js +5 -2
- package/lib/rules/common/path-excludes-patterns.d.ts +1 -2
- package/lib/rules/common/path-excludes-patterns.js +5 -2
- package/lib/rules/common/path-http-verbs-order.d.ts +1 -2
- package/lib/rules/common/path-http-verbs-order.js +5 -2
- package/lib/rules/common/path-not-include-query.d.ts +1 -2
- package/lib/rules/common/path-not-include-query.js +5 -2
- package/lib/rules/common/path-params-defined.d.ts +1 -2
- package/lib/rules/common/path-params-defined.js +5 -2
- package/lib/rules/common/path-segment-plural.d.ts +1 -2
- package/lib/rules/common/path-segment-plural.js +8 -5
- package/lib/rules/common/paths-kebab-case.d.ts +1 -2
- package/lib/rules/common/paths-kebab-case.js +5 -2
- package/lib/rules/common/required-string-property-missing-min-length.d.ts +1 -2
- package/lib/rules/common/required-string-property-missing-min-length.js +5 -2
- package/lib/rules/common/response-contains-header.d.ts +1 -2
- package/lib/rules/common/response-contains-header.js +8 -5
- package/lib/rules/common/scalar-property-missing-example.d.ts +1 -2
- package/lib/rules/common/scalar-property-missing-example.js +7 -4
- package/lib/rules/common/security-defined.d.ts +1 -2
- package/lib/rules/common/security-defined.js +5 -2
- package/lib/rules/common/spec-strict-refs.d.ts +1 -2
- package/lib/rules/common/spec-strict-refs.js +7 -4
- package/lib/rules/common/struct.d.ts +1 -2
- package/lib/rules/common/struct.js +21 -18
- package/lib/rules/common/tag-description.d.ts +1 -2
- package/lib/rules/common/tag-description.js +7 -4
- package/lib/rules/common/tags-alphabetical.d.ts +1 -2
- package/lib/rules/common/tags-alphabetical.js +5 -2
- package/lib/rules/no-unresolved-refs.d.ts +3 -4
- package/lib/rules/no-unresolved-refs.js +9 -5
- package/lib/rules/oas2/boolean-parameter-prefixes.d.ts +1 -2
- package/lib/rules/oas2/boolean-parameter-prefixes.js +5 -2
- package/lib/rules/oas2/index.d.ts +1 -2
- package/lib/rules/oas2/index.js +97 -95
- package/lib/rules/oas2/request-mime-type.d.ts +1 -2
- package/lib/rules/oas2/request-mime-type.js +8 -5
- package/lib/rules/oas2/response-contains-property.d.ts +1 -2
- package/lib/rules/oas2/response-contains-property.js +8 -5
- package/lib/rules/oas2/response-mime-type.d.ts +1 -2
- package/lib/rules/oas2/response-mime-type.js +8 -5
- package/lib/rules/oas3/array-parameter-serialization.d.ts +1 -2
- package/lib/rules/oas3/array-parameter-serialization.js +7 -4
- package/lib/rules/oas3/boolean-parameter-prefixes.d.ts +1 -2
- package/lib/rules/oas3/boolean-parameter-prefixes.js +5 -2
- package/lib/rules/oas3/component-name-unique.d.ts +1 -2
- package/lib/rules/oas3/component-name-unique.js +5 -2
- package/lib/rules/oas3/index.d.ts +1 -2
- package/lib/rules/oas3/index.js +121 -119
- package/lib/rules/oas3/no-empty-servers.d.ts +1 -2
- package/lib/rules/oas3/no-empty-servers.js +5 -2
- package/lib/rules/oas3/no-example-value-and-externalValue.d.ts +1 -2
- package/lib/rules/oas3/no-example-value-and-externalValue.js +5 -2
- package/lib/rules/oas3/no-invalid-media-type-examples.d.ts +1 -2
- package/lib/rules/oas3/no-invalid-media-type-examples.js +10 -7
- package/lib/rules/oas3/no-server-example.com.d.ts +1 -2
- package/lib/rules/oas3/no-server-example.com.js +5 -2
- package/lib/rules/oas3/no-server-trailing-slash.d.ts +1 -2
- package/lib/rules/oas3/no-server-trailing-slash.js +5 -2
- package/lib/rules/oas3/no-server-variables-empty-enum.d.ts +1 -2
- package/lib/rules/oas3/no-server-variables-empty-enum.js +5 -2
- package/lib/rules/oas3/no-undefined-server-variable.d.ts +1 -2
- package/lib/rules/oas3/no-undefined-server-variable.js +5 -2
- package/lib/rules/oas3/no-unused-components.d.ts +1 -2
- package/lib/rules/oas3/no-unused-components.js +5 -2
- package/lib/rules/oas3/operation-4xx-problem-details-rfc7807.d.ts +1 -2
- package/lib/rules/oas3/operation-4xx-problem-details-rfc7807.js +9 -6
- package/lib/rules/oas3/request-mime-type.d.ts +1 -2
- package/lib/rules/oas3/request-mime-type.js +9 -6
- package/lib/rules/oas3/response-contains-property.d.ts +1 -2
- package/lib/rules/oas3/response-contains-property.js +8 -5
- package/lib/rules/oas3/response-mime-type.d.ts +1 -2
- package/lib/rules/oas3/response-mime-type.js +9 -6
- package/lib/rules/oas3/spec-components-invalid-map-name.d.ts +1 -2
- package/lib/rules/oas3/spec-components-invalid-map-name.js +5 -2
- package/lib/rules/other/stats.d.ts +3 -4
- package/lib/rules/other/stats.js +5 -2
- package/lib/rules/overlay1/index.d.ts +1 -2
- package/lib/rules/overlay1/index.js +11 -9
- package/lib/rules/respect/no-criteria-xpath.d.ts +1 -2
- package/lib/rules/respect/no-criteria-xpath.js +5 -2
- package/lib/rules/respect/respect-supported-versions.d.ts +1 -2
- package/lib/rules/respect/respect-supported-versions.js +10 -7
- package/lib/rules/utils.d.ts +3 -4
- package/lib/rules/utils.js +36 -23
- package/lib/types/arazzo.d.ts +1 -2
- package/lib/types/arazzo.js +23 -21
- package/lib/types/asyncapi2.d.ts +1 -2
- package/lib/types/asyncapi2.js +56 -54
- package/lib/types/asyncapi3.d.ts +1 -2
- package/lib/types/asyncapi3.js +43 -41
- package/lib/types/index.d.ts +0 -1
- package/lib/types/index.js +13 -7
- package/lib/types/json-schema-adapter.d.ts +1 -2
- package/lib/types/json-schema-adapter.js +17 -15
- package/lib/types/oas2.d.ts +2 -3
- package/lib/types/oas2.js +19 -17
- package/lib/types/oas3.d.ts +2 -3
- package/lib/types/oas3.js +41 -39
- package/lib/types/oas3_1.d.ts +2 -3
- package/lib/types/oas3_1.js +20 -18
- package/lib/types/overlay.d.ts +1 -2
- package/lib/types/overlay.js +6 -4
- package/lib/types/redocly-yaml.d.ts +3 -4
- package/lib/types/redocly-yaml.js +48 -31
- package/lib/typings/arazzo.d.ts +0 -1
- package/lib/typings/arazzo.js +5 -3
- package/lib/typings/asyncapi.d.ts +0 -1
- package/lib/typings/asyncapi.js +2 -2
- package/lib/typings/asyncapi3.d.ts +0 -1
- package/lib/typings/asyncapi3.js +2 -2
- package/lib/typings/common.d.ts +0 -1
- package/lib/typings/common.js +2 -2
- package/lib/typings/openapi.d.ts +0 -1
- package/lib/typings/openapi.js +2 -2
- package/lib/typings/overlay.d.ts +0 -1
- package/lib/typings/overlay.js +4 -2
- package/lib/typings/swagger.d.ts +1 -2
- package/lib/typings/swagger.js +2 -2
- package/lib/utils.d.ts +5 -4
- package/lib/utils.js +99 -52
- package/lib/visitors.d.ts +10 -11
- package/lib/visitors.js +6 -4
- package/lib/walk.d.ts +8 -9
- package/lib/walk.js +25 -23
- package/package.json +9 -30
- package/lib/benchmark/benches/lint-with-many-rules.bench.d.ts.map +0 -1
- package/lib/benchmark/benches/lint-with-many-rules.bench.js.map +0 -1
- package/lib/benchmark/benches/lint-with-nested-rule.bench.d.ts.map +0 -1
- package/lib/benchmark/benches/lint-with-nested-rule.bench.js.map +0 -1
- package/lib/benchmark/benches/lint-with-no-rules.bench.d.ts.map +0 -1
- package/lib/benchmark/benches/lint-with-no-rules.bench.js.map +0 -1
- package/lib/benchmark/benches/lint-with-top-level-rule-report.bench.d.ts.map +0 -1
- package/lib/benchmark/benches/lint-with-top-level-rule-report.bench.js.map +0 -1
- package/lib/benchmark/benches/lint-with-top-level-rule.bench.d.ts.map +0 -1
- package/lib/benchmark/benches/lint-with-top-level-rule.bench.js.map +0 -1
- package/lib/benchmark/benches/recommended-oas3.bench.d.ts.map +0 -1
- package/lib/benchmark/benches/recommended-oas3.bench.js.map +0 -1
- package/lib/benchmark/benches/resolve-with-no-external.bench.d.ts.map +0 -1
- package/lib/benchmark/benches/resolve-with-no-external.bench.js.map +0 -1
- package/lib/benchmark/utils.d.ts.map +0 -1
- package/lib/benchmark/utils.js.map +0 -1
- package/lib/bundle.d.ts.map +0 -1
- package/lib/bundle.js.map +0 -1
- package/lib/config/all.d.ts.map +0 -1
- package/lib/config/all.js.map +0 -1
- package/lib/config/builtIn.d.ts.map +0 -1
- package/lib/config/builtIn.js.map +0 -1
- package/lib/config/config-resolvers.d.ts.map +0 -1
- package/lib/config/config-resolvers.js.map +0 -1
- package/lib/config/config.d.ts.map +0 -1
- package/lib/config/config.js.map +0 -1
- package/lib/config/index.d.ts.map +0 -1
- package/lib/config/index.js.map +0 -1
- package/lib/config/load.d.ts.map +0 -1
- package/lib/config/load.js.map +0 -1
- package/lib/config/minimal.d.ts.map +0 -1
- package/lib/config/minimal.js.map +0 -1
- package/lib/config/recommended-strict.d.ts.map +0 -1
- package/lib/config/recommended-strict.js.map +0 -1
- package/lib/config/recommended.d.ts.map +0 -1
- package/lib/config/recommended.js.map +0 -1
- package/lib/config/rules.d.ts.map +0 -1
- package/lib/config/rules.js.map +0 -1
- package/lib/config/spec.d.ts.map +0 -1
- package/lib/config/spec.js.map +0 -1
- package/lib/config/types.d.ts.map +0 -1
- package/lib/config/types.js.map +0 -1
- package/lib/config/utils.d.ts.map +0 -1
- package/lib/config/utils.js.map +0 -1
- package/lib/decorators/arazzo/index.d.ts.map +0 -1
- package/lib/decorators/arazzo/index.js.map +0 -1
- package/lib/decorators/async2/index.d.ts.map +0 -1
- package/lib/decorators/async2/index.js.map +0 -1
- package/lib/decorators/async3/index.d.ts.map +0 -1
- package/lib/decorators/async3/index.js.map +0 -1
- package/lib/decorators/common/filters/filter-helper.d.ts.map +0 -1
- package/lib/decorators/common/filters/filter-helper.js.map +0 -1
- package/lib/decorators/common/filters/filter-in.d.ts.map +0 -1
- package/lib/decorators/common/filters/filter-in.js.map +0 -1
- package/lib/decorators/common/filters/filter-out.d.ts.map +0 -1
- package/lib/decorators/common/filters/filter-out.js.map +0 -1
- package/lib/decorators/common/info-description-override.d.ts.map +0 -1
- package/lib/decorators/common/info-description-override.js.map +0 -1
- package/lib/decorators/common/info-override.d.ts.map +0 -1
- package/lib/decorators/common/info-override.js.map +0 -1
- package/lib/decorators/common/media-type-examples-override.d.ts.map +0 -1
- package/lib/decorators/common/media-type-examples-override.js.map +0 -1
- package/lib/decorators/common/operation-description-override.d.ts.map +0 -1
- package/lib/decorators/common/operation-description-override.js.map +0 -1
- package/lib/decorators/common/remove-x-internal.d.ts.map +0 -1
- package/lib/decorators/common/remove-x-internal.js.map +0 -1
- package/lib/decorators/common/tag-description-override.d.ts.map +0 -1
- package/lib/decorators/common/tag-description-override.js.map +0 -1
- package/lib/decorators/oas2/index.d.ts.map +0 -1
- package/lib/decorators/oas2/index.js.map +0 -1
- package/lib/decorators/oas2/remove-unused-components.d.ts.map +0 -1
- package/lib/decorators/oas2/remove-unused-components.js.map +0 -1
- package/lib/decorators/oas3/index.d.ts.map +0 -1
- package/lib/decorators/oas3/index.js.map +0 -1
- package/lib/decorators/oas3/remove-unused-components.d.ts.map +0 -1
- package/lib/decorators/oas3/remove-unused-components.js.map +0 -1
- package/lib/decorators/overlay1/index.d.ts.map +0 -1
- package/lib/decorators/overlay1/index.js.map +0 -1
- package/lib/env.d.ts.map +0 -1
- package/lib/env.js.map +0 -1
- package/lib/format/codeframes.d.ts.map +0 -1
- package/lib/format/codeframes.js.map +0 -1
- package/lib/format/format.d.ts.map +0 -1
- package/lib/format/format.js.map +0 -1
- package/lib/index.d.ts.map +0 -1
- package/lib/index.js.map +0 -1
- package/lib/js-yaml/index.d.ts.map +0 -1
- package/lib/js-yaml/index.js.map +0 -1
- package/lib/lint.d.ts.map +0 -1
- package/lib/lint.js.map +0 -1
- package/lib/logger.d.ts.map +0 -1
- package/lib/logger.js.map +0 -1
- package/lib/oas-types.d.ts.map +0 -1
- package/lib/oas-types.js.map +0 -1
- package/lib/ref-utils.d.ts.map +0 -1
- package/lib/ref-utils.js.map +0 -1
- package/lib/resolve.d.ts.map +0 -1
- package/lib/resolve.js.map +0 -1
- package/lib/rules/ajv.d.ts.map +0 -1
- package/lib/rules/ajv.js.map +0 -1
- package/lib/rules/arazzo/criteria-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/criteria-unique.js.map +0 -1
- package/lib/rules/arazzo/index.d.ts.map +0 -1
- package/lib/rules/arazzo/index.js.map +0 -1
- package/lib/rules/arazzo/parameters-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/parameters-unique.js.map +0 -1
- package/lib/rules/arazzo/requestBody-replacements-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/requestBody-replacements-unique.js.map +0 -1
- package/lib/rules/arazzo/sourceDescription-type.d.ts.map +0 -1
- package/lib/rules/arazzo/sourceDescription-type.js.map +0 -1
- package/lib/rules/arazzo/sourceDescriptions-name-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/sourceDescriptions-name-unique.js.map +0 -1
- package/lib/rules/arazzo/sourceDescriptions-not-empty.d.ts.map +0 -1
- package/lib/rules/arazzo/sourceDescriptions-not-empty.js.map +0 -1
- package/lib/rules/arazzo/step-onFailure-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/step-onFailure-unique.js.map +0 -1
- package/lib/rules/arazzo/step-onSuccess-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/step-onSuccess-unique.js.map +0 -1
- package/lib/rules/arazzo/stepId-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/stepId-unique.js.map +0 -1
- package/lib/rules/arazzo/workflow-dependsOn.d.ts.map +0 -1
- package/lib/rules/arazzo/workflow-dependsOn.js.map +0 -1
- package/lib/rules/arazzo/workflowId-unique.d.ts.map +0 -1
- package/lib/rules/arazzo/workflowId-unique.js.map +0 -1
- package/lib/rules/async2/channels-kebab-case.d.ts.map +0 -1
- package/lib/rules/async2/channels-kebab-case.js.map +0 -1
- package/lib/rules/async2/index.d.ts.map +0 -1
- package/lib/rules/async2/index.js.map +0 -1
- package/lib/rules/async2/no-channel-trailing-slash.d.ts.map +0 -1
- package/lib/rules/async2/no-channel-trailing-slash.js.map +0 -1
- package/lib/rules/async3/channels-kebab-case.d.ts.map +0 -1
- package/lib/rules/async3/channels-kebab-case.js.map +0 -1
- package/lib/rules/async3/index.d.ts.map +0 -1
- package/lib/rules/async3/index.js.map +0 -1
- package/lib/rules/async3/no-channel-trailing-slash.d.ts.map +0 -1
- package/lib/rules/async3/no-channel-trailing-slash.js.map +0 -1
- package/lib/rules/common/assertions/asserts.d.ts.map +0 -1
- package/lib/rules/common/assertions/asserts.js.map +0 -1
- package/lib/rules/common/assertions/index.d.ts.map +0 -1
- package/lib/rules/common/assertions/index.js.map +0 -1
- package/lib/rules/common/assertions/utils.d.ts.map +0 -1
- package/lib/rules/common/assertions/utils.js.map +0 -1
- package/lib/rules/common/info-contact.d.ts.map +0 -1
- package/lib/rules/common/info-contact.js.map +0 -1
- package/lib/rules/common/info-license-strict.d.ts.map +0 -1
- package/lib/rules/common/info-license-strict.js.map +0 -1
- package/lib/rules/common/info-license-url.d.ts.map +0 -1
- package/lib/rules/common/info-license-url.js.map +0 -1
- package/lib/rules/common/info-license.d.ts.map +0 -1
- package/lib/rules/common/info-license.js.map +0 -1
- package/lib/rules/common/no-ambiguous-paths.d.ts.map +0 -1
- package/lib/rules/common/no-ambiguous-paths.js.map +0 -1
- package/lib/rules/common/no-enum-type-mismatch.d.ts.map +0 -1
- package/lib/rules/common/no-enum-type-mismatch.js.map +0 -1
- package/lib/rules/common/no-http-verbs-in-paths.d.ts.map +0 -1
- package/lib/rules/common/no-http-verbs-in-paths.js.map +0 -1
- package/lib/rules/common/no-identical-paths.d.ts.map +0 -1
- package/lib/rules/common/no-identical-paths.js.map +0 -1
- package/lib/rules/common/no-invalid-parameter-examples.d.ts.map +0 -1
- package/lib/rules/common/no-invalid-parameter-examples.js.map +0 -1
- package/lib/rules/common/no-invalid-schema-examples.d.ts.map +0 -1
- package/lib/rules/common/no-invalid-schema-examples.js.map +0 -1
- package/lib/rules/common/no-path-trailing-slash.d.ts.map +0 -1
- package/lib/rules/common/no-path-trailing-slash.js.map +0 -1
- package/lib/rules/common/no-required-schema-properties-undefined.d.ts.map +0 -1
- package/lib/rules/common/no-required-schema-properties-undefined.js.map +0 -1
- package/lib/rules/common/no-schema-type-mismatch.d.ts.map +0 -1
- package/lib/rules/common/no-schema-type-mismatch.js.map +0 -1
- package/lib/rules/common/operation-2xx-response.d.ts.map +0 -1
- package/lib/rules/common/operation-2xx-response.js.map +0 -1
- package/lib/rules/common/operation-4xx-response.d.ts.map +0 -1
- package/lib/rules/common/operation-4xx-response.js.map +0 -1
- package/lib/rules/common/operation-description.d.ts.map +0 -1
- package/lib/rules/common/operation-description.js.map +0 -1
- package/lib/rules/common/operation-operationId-unique.d.ts.map +0 -1
- package/lib/rules/common/operation-operationId-unique.js.map +0 -1
- package/lib/rules/common/operation-operationId-url-safe.d.ts.map +0 -1
- package/lib/rules/common/operation-operationId-url-safe.js.map +0 -1
- package/lib/rules/common/operation-operationId.d.ts.map +0 -1
- package/lib/rules/common/operation-operationId.js.map +0 -1
- package/lib/rules/common/operation-parameters-unique.d.ts.map +0 -1
- package/lib/rules/common/operation-parameters-unique.js.map +0 -1
- package/lib/rules/common/operation-singular-tag.d.ts.map +0 -1
- package/lib/rules/common/operation-singular-tag.js.map +0 -1
- package/lib/rules/common/operation-summary.d.ts.map +0 -1
- package/lib/rules/common/operation-summary.js.map +0 -1
- package/lib/rules/common/operation-tag-defined.d.ts.map +0 -1
- package/lib/rules/common/operation-tag-defined.js.map +0 -1
- package/lib/rules/common/parameter-description.d.ts.map +0 -1
- package/lib/rules/common/parameter-description.js.map +0 -1
- package/lib/rules/common/path-declaration-must-exist.d.ts.map +0 -1
- package/lib/rules/common/path-declaration-must-exist.js.map +0 -1
- package/lib/rules/common/path-excludes-patterns.d.ts.map +0 -1
- package/lib/rules/common/path-excludes-patterns.js.map +0 -1
- package/lib/rules/common/path-http-verbs-order.d.ts.map +0 -1
- package/lib/rules/common/path-http-verbs-order.js.map +0 -1
- package/lib/rules/common/path-not-include-query.d.ts.map +0 -1
- package/lib/rules/common/path-not-include-query.js.map +0 -1
- package/lib/rules/common/path-params-defined.d.ts.map +0 -1
- package/lib/rules/common/path-params-defined.js.map +0 -1
- package/lib/rules/common/path-segment-plural.d.ts.map +0 -1
- package/lib/rules/common/path-segment-plural.js.map +0 -1
- package/lib/rules/common/paths-kebab-case.d.ts.map +0 -1
- package/lib/rules/common/paths-kebab-case.js.map +0 -1
- package/lib/rules/common/required-string-property-missing-min-length.d.ts.map +0 -1
- package/lib/rules/common/required-string-property-missing-min-length.js.map +0 -1
- package/lib/rules/common/response-contains-header.d.ts.map +0 -1
- package/lib/rules/common/response-contains-header.js.map +0 -1
- package/lib/rules/common/scalar-property-missing-example.d.ts.map +0 -1
- package/lib/rules/common/scalar-property-missing-example.js.map +0 -1
- package/lib/rules/common/security-defined.d.ts.map +0 -1
- package/lib/rules/common/security-defined.js.map +0 -1
- package/lib/rules/common/spec-strict-refs.d.ts.map +0 -1
- package/lib/rules/common/spec-strict-refs.js.map +0 -1
- package/lib/rules/common/struct.d.ts.map +0 -1
- package/lib/rules/common/struct.js.map +0 -1
- package/lib/rules/common/tag-description.d.ts.map +0 -1
- package/lib/rules/common/tag-description.js.map +0 -1
- package/lib/rules/common/tags-alphabetical.d.ts.map +0 -1
- package/lib/rules/common/tags-alphabetical.js.map +0 -1
- package/lib/rules/no-unresolved-refs.d.ts.map +0 -1
- package/lib/rules/no-unresolved-refs.js.map +0 -1
- package/lib/rules/oas2/boolean-parameter-prefixes.d.ts.map +0 -1
- package/lib/rules/oas2/boolean-parameter-prefixes.js.map +0 -1
- package/lib/rules/oas2/index.d.ts.map +0 -1
- package/lib/rules/oas2/index.js.map +0 -1
- package/lib/rules/oas2/request-mime-type.d.ts.map +0 -1
- package/lib/rules/oas2/request-mime-type.js.map +0 -1
- package/lib/rules/oas2/response-contains-property.d.ts.map +0 -1
- package/lib/rules/oas2/response-contains-property.js.map +0 -1
- package/lib/rules/oas2/response-mime-type.d.ts.map +0 -1
- package/lib/rules/oas2/response-mime-type.js.map +0 -1
- package/lib/rules/oas3/array-parameter-serialization.d.ts.map +0 -1
- package/lib/rules/oas3/array-parameter-serialization.js.map +0 -1
- package/lib/rules/oas3/boolean-parameter-prefixes.d.ts.map +0 -1
- package/lib/rules/oas3/boolean-parameter-prefixes.js.map +0 -1
- package/lib/rules/oas3/component-name-unique.d.ts.map +0 -1
- package/lib/rules/oas3/component-name-unique.js.map +0 -1
- package/lib/rules/oas3/index.d.ts.map +0 -1
- package/lib/rules/oas3/index.js.map +0 -1
- package/lib/rules/oas3/no-empty-servers.d.ts.map +0 -1
- package/lib/rules/oas3/no-empty-servers.js.map +0 -1
- package/lib/rules/oas3/no-example-value-and-externalValue.d.ts.map +0 -1
- package/lib/rules/oas3/no-example-value-and-externalValue.js.map +0 -1
- package/lib/rules/oas3/no-invalid-media-type-examples.d.ts.map +0 -1
- package/lib/rules/oas3/no-invalid-media-type-examples.js.map +0 -1
- package/lib/rules/oas3/no-server-example.com.d.ts.map +0 -1
- package/lib/rules/oas3/no-server-example.com.js.map +0 -1
- package/lib/rules/oas3/no-server-trailing-slash.d.ts.map +0 -1
- package/lib/rules/oas3/no-server-trailing-slash.js.map +0 -1
- package/lib/rules/oas3/no-server-variables-empty-enum.d.ts.map +0 -1
- package/lib/rules/oas3/no-server-variables-empty-enum.js.map +0 -1
- package/lib/rules/oas3/no-undefined-server-variable.d.ts.map +0 -1
- package/lib/rules/oas3/no-undefined-server-variable.js.map +0 -1
- package/lib/rules/oas3/no-unused-components.d.ts.map +0 -1
- package/lib/rules/oas3/no-unused-components.js.map +0 -1
- package/lib/rules/oas3/operation-4xx-problem-details-rfc7807.d.ts.map +0 -1
- package/lib/rules/oas3/operation-4xx-problem-details-rfc7807.js.map +0 -1
- package/lib/rules/oas3/request-mime-type.d.ts.map +0 -1
- package/lib/rules/oas3/request-mime-type.js.map +0 -1
- package/lib/rules/oas3/response-contains-property.d.ts.map +0 -1
- package/lib/rules/oas3/response-contains-property.js.map +0 -1
- package/lib/rules/oas3/response-mime-type.d.ts.map +0 -1
- package/lib/rules/oas3/response-mime-type.js.map +0 -1
- package/lib/rules/oas3/spec-components-invalid-map-name.d.ts.map +0 -1
- package/lib/rules/oas3/spec-components-invalid-map-name.js.map +0 -1
- package/lib/rules/other/stats.d.ts.map +0 -1
- package/lib/rules/other/stats.js.map +0 -1
- package/lib/rules/overlay1/index.d.ts.map +0 -1
- package/lib/rules/overlay1/index.js.map +0 -1
- package/lib/rules/respect/no-criteria-xpath.d.ts.map +0 -1
- package/lib/rules/respect/no-criteria-xpath.js.map +0 -1
- package/lib/rules/respect/respect-supported-versions.d.ts.map +0 -1
- package/lib/rules/respect/respect-supported-versions.js.map +0 -1
- package/lib/rules/utils.d.ts.map +0 -1
- package/lib/rules/utils.js.map +0 -1
- package/lib/types/arazzo.d.ts.map +0 -1
- package/lib/types/arazzo.js.map +0 -1
- package/lib/types/asyncapi2.d.ts.map +0 -1
- package/lib/types/asyncapi2.js.map +0 -1
- package/lib/types/asyncapi3.d.ts.map +0 -1
- package/lib/types/asyncapi3.js.map +0 -1
- package/lib/types/index.d.ts.map +0 -1
- package/lib/types/index.js.map +0 -1
- package/lib/types/json-schema-adapter.d.ts.map +0 -1
- package/lib/types/json-schema-adapter.js.map +0 -1
- package/lib/types/oas2.d.ts.map +0 -1
- package/lib/types/oas2.js.map +0 -1
- package/lib/types/oas3.d.ts.map +0 -1
- package/lib/types/oas3.js.map +0 -1
- package/lib/types/oas3_1.d.ts.map +0 -1
- package/lib/types/oas3_1.js.map +0 -1
- package/lib/types/overlay.d.ts.map +0 -1
- package/lib/types/overlay.js.map +0 -1
- package/lib/types/redocly-yaml.d.ts.map +0 -1
- package/lib/types/redocly-yaml.js.map +0 -1
- package/lib/typings/arazzo.d.ts.map +0 -1
- package/lib/typings/arazzo.js.map +0 -1
- package/lib/typings/asyncapi.d.ts.map +0 -1
- package/lib/typings/asyncapi.js.map +0 -1
- package/lib/typings/asyncapi3.d.ts.map +0 -1
- package/lib/typings/asyncapi3.js.map +0 -1
- package/lib/typings/common.d.ts.map +0 -1
- package/lib/typings/common.js.map +0 -1
- package/lib/typings/openapi.d.ts.map +0 -1
- package/lib/typings/openapi.js.map +0 -1
- package/lib/typings/overlay.d.ts.map +0 -1
- package/lib/typings/overlay.js.map +0 -1
- package/lib/typings/swagger.d.ts.map +0 -1
- package/lib/typings/swagger.js.map +0 -1
- package/lib/utils/error.d.ts +0 -3
- package/lib/utils/error.d.ts.map +0 -1
- package/lib/utils/error.js +0 -3
- package/lib/utils/error.js.map +0 -1
- package/lib/utils.d.ts.map +0 -1
- package/lib/utils.js.map +0 -1
- package/lib/visitors.d.ts.map +0 -1
- package/lib/visitors.js.map +0 -1
- package/lib/walk.d.ts.map +0 -1
- package/lib/walk.js.map +0 -1
|
@@ -1,21 +1,28 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.resolveConfigFileAndRefs = resolveConfigFileAndRefs;
|
|
4
|
+
exports.resolveConfig = resolveConfig;
|
|
5
|
+
exports.resolvePlugins = resolvePlugins;
|
|
6
|
+
exports.resolveApis = resolveApis;
|
|
7
|
+
exports.resolveStyleguideConfig = resolveStyleguideConfig;
|
|
8
|
+
exports.resolvePreset = resolvePreset;
|
|
9
|
+
const path = require("path");
|
|
10
|
+
const url_1 = require("url");
|
|
11
|
+
const fs_1 = require("fs");
|
|
12
|
+
const ref_utils_1 = require("../ref-utils");
|
|
13
|
+
const utils_1 = require("../utils");
|
|
14
|
+
const resolve_1 = require("../resolve");
|
|
15
|
+
const builtIn_1 = require("./builtIn");
|
|
16
|
+
const utils_2 = require("./utils");
|
|
17
|
+
const env_1 = require("../env");
|
|
18
|
+
const config_1 = require("./config");
|
|
19
|
+
const logger_1 = require("../logger");
|
|
20
|
+
const asserts_1 = require("../rules/common/assertions/asserts");
|
|
21
|
+
const redocly_yaml_1 = require("../types/redocly-yaml");
|
|
15
22
|
const DEFAULT_PROJECT_PLUGIN_PATHS = ['@theme/plugin.js', '@theme/plugin.cjs', '@theme/plugin.mjs'];
|
|
16
23
|
// Cache instantiated plugins during a single execution
|
|
17
24
|
const pluginsCache = new Map();
|
|
18
|
-
|
|
25
|
+
async function resolveConfigFileAndRefs({ configPath, externalRefResolver = new resolve_1.BaseResolver(), base = null, }) {
|
|
19
26
|
if (!configPath) {
|
|
20
27
|
throw new Error('Reference to a config is required.\n');
|
|
21
28
|
}
|
|
@@ -23,18 +30,18 @@ export async function resolveConfigFileAndRefs({ configPath, externalRefResolver
|
|
|
23
30
|
if (document instanceof Error) {
|
|
24
31
|
throw document;
|
|
25
32
|
}
|
|
26
|
-
const resolvedRefMap = await resolveDocument({
|
|
33
|
+
const resolvedRefMap = await (0, resolve_1.resolveDocument)({
|
|
27
34
|
rootDocument: document,
|
|
28
|
-
rootType: NormalizedConfigTypes.ConfigRoot,
|
|
35
|
+
rootType: redocly_yaml_1.NormalizedConfigTypes.ConfigRoot,
|
|
29
36
|
externalRefResolver,
|
|
30
37
|
});
|
|
31
38
|
return { document, resolvedRefMap };
|
|
32
39
|
}
|
|
33
|
-
|
|
34
|
-
if (rawConfig.styleguide?.extends?.some(isNotString)) {
|
|
40
|
+
async function resolveConfig({ rawConfig, configPath, externalRefResolver, }) {
|
|
41
|
+
if (rawConfig.styleguide?.extends?.some(utils_1.isNotString)) {
|
|
35
42
|
throw new Error(`Error configuration format not detected in extends value must contain strings`);
|
|
36
43
|
}
|
|
37
|
-
const resolver = externalRefResolver ?? new BaseResolver(getResolveConfig(rawConfig.resolve));
|
|
44
|
+
const resolver = externalRefResolver ?? new resolve_1.BaseResolver((0, utils_2.getResolveConfig)(rawConfig.resolve));
|
|
38
45
|
const apis = await resolveApis({
|
|
39
46
|
rawConfig,
|
|
40
47
|
configPath,
|
|
@@ -45,7 +52,7 @@ export async function resolveConfig({ rawConfig, configPath, externalRefResolver
|
|
|
45
52
|
configPath,
|
|
46
53
|
resolver,
|
|
47
54
|
});
|
|
48
|
-
return new Config({
|
|
55
|
+
return new config_1.Config({
|
|
49
56
|
...rawConfig,
|
|
50
57
|
apis,
|
|
51
58
|
styleguide,
|
|
@@ -54,52 +61,55 @@ export async function resolveConfig({ rawConfig, configPath, externalRefResolver
|
|
|
54
61
|
function getDefaultPluginPath(configDir) {
|
|
55
62
|
for (const pluginPath of DEFAULT_PROJECT_PLUGIN_PATHS) {
|
|
56
63
|
const absolutePluginPath = path.resolve(configDir, pluginPath);
|
|
57
|
-
if (
|
|
64
|
+
if ((0, fs_1.existsSync)(absolutePluginPath)) {
|
|
58
65
|
return pluginPath;
|
|
59
66
|
}
|
|
60
67
|
}
|
|
61
68
|
return;
|
|
62
69
|
}
|
|
63
|
-
|
|
70
|
+
async function resolvePlugins(plugins, configDir = '') {
|
|
64
71
|
if (!plugins)
|
|
65
72
|
return [];
|
|
66
73
|
// TODO: implement or reuse Resolver approach so it will work in node and browser envs
|
|
67
74
|
const requireFunc = async (plugin) => {
|
|
68
|
-
if (isString(plugin)) {
|
|
75
|
+
if ((0, utils_1.isString)(plugin)) {
|
|
69
76
|
try {
|
|
70
77
|
const maybeAbsolutePluginPath = path.resolve(configDir, plugin);
|
|
71
|
-
const absolutePluginPath =
|
|
78
|
+
const absolutePluginPath = (0, fs_1.existsSync)(maybeAbsolutePluginPath)
|
|
72
79
|
? maybeAbsolutePluginPath
|
|
73
80
|
: // For plugins imported from packages specifically
|
|
74
|
-
|
|
81
|
+
require.resolve(plugin, {
|
|
75
82
|
paths: [
|
|
76
83
|
// Plugins imported from the node_modules in the project directory
|
|
77
84
|
configDir,
|
|
78
85
|
// Plugins imported from the node_modules in the package install directory (for example, npx cache directory)
|
|
79
|
-
|
|
86
|
+
__dirname,
|
|
80
87
|
],
|
|
81
88
|
});
|
|
82
89
|
if (!pluginsCache.has(absolutePluginPath)) {
|
|
83
90
|
let requiredPlugin;
|
|
84
91
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
85
|
-
// @ts-ignore
|
|
92
|
+
// @ts-ignore
|
|
86
93
|
if (typeof __webpack_require__ === 'function') {
|
|
87
94
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
88
|
-
// @ts-ignore
|
|
95
|
+
// @ts-ignore
|
|
89
96
|
requiredPlugin = __non_webpack_require__(absolutePluginPath);
|
|
90
97
|
}
|
|
91
98
|
else {
|
|
92
|
-
|
|
99
|
+
// Workaround for dynamic imports being transpiled to require by Typescript: https://github.com/microsoft/TypeScript/issues/43329#issuecomment-811606238
|
|
100
|
+
const _importDynamic = new Function('modulePath', 'return import(modulePath)');
|
|
101
|
+
// you can import both cjs and mjs
|
|
102
|
+
const mod = await _importDynamic((0, url_1.pathToFileURL)(absolutePluginPath).href);
|
|
93
103
|
requiredPlugin = mod.default || mod;
|
|
94
104
|
}
|
|
95
105
|
const pluginCreatorOptions = { contentDir: configDir };
|
|
96
|
-
const pluginModule = isDeprecatedPluginFormat(requiredPlugin)
|
|
106
|
+
const pluginModule = (0, utils_2.isDeprecatedPluginFormat)(requiredPlugin)
|
|
97
107
|
? requiredPlugin
|
|
98
|
-
: isCommonJsPlugin(requiredPlugin)
|
|
108
|
+
: (0, utils_2.isCommonJsPlugin)(requiredPlugin)
|
|
99
109
|
? await requiredPlugin(pluginCreatorOptions)
|
|
100
110
|
: await requiredPlugin?.default?.(pluginCreatorOptions);
|
|
101
|
-
if (pluginModule?.id && isDeprecatedPluginFormat(requiredPlugin)) {
|
|
102
|
-
logger.info(`Deprecated plugin format detected: ${pluginModule.id}\n`);
|
|
111
|
+
if (pluginModule?.id && (0, utils_2.isDeprecatedPluginFormat)(requiredPlugin)) {
|
|
112
|
+
logger_1.logger.info(`Deprecated plugin format detected: ${pluginModule.id}\n`);
|
|
103
113
|
}
|
|
104
114
|
if (pluginModule) {
|
|
105
115
|
pluginsCache.set(absolutePluginPath, {
|
|
@@ -127,9 +137,9 @@ export async function resolvePlugins(plugins, configDir = '') {
|
|
|
127
137
|
}
|
|
128
138
|
const resolvedPlugins = new Set();
|
|
129
139
|
const instances = await Promise.all(plugins.map(async (p) => {
|
|
130
|
-
if (isString(p)) {
|
|
131
|
-
if (isAbsoluteUrl(p)) {
|
|
132
|
-
throw new Error(colorize.red(`We don't support remote plugins yet.`));
|
|
140
|
+
if ((0, utils_1.isString)(p)) {
|
|
141
|
+
if ((0, ref_utils_1.isAbsoluteUrl)(p)) {
|
|
142
|
+
throw new Error(logger_1.colorize.red(`We don't support remote plugins yet.`));
|
|
133
143
|
}
|
|
134
144
|
if (resolvedPlugins.has(p)) {
|
|
135
145
|
return;
|
|
@@ -142,11 +152,11 @@ export async function resolvePlugins(plugins, configDir = '') {
|
|
|
142
152
|
}
|
|
143
153
|
const id = pluginModule.id;
|
|
144
154
|
if (typeof id !== 'string') {
|
|
145
|
-
throw new Error(colorize.red(`Plugin must define \`id\` property in ${colorize.blue(p.toString())}.`));
|
|
155
|
+
throw new Error(logger_1.colorize.red(`Plugin must define \`id\` property in ${logger_1.colorize.blue(p.toString())}.`));
|
|
146
156
|
}
|
|
147
157
|
if (seenPluginIds.has(id)) {
|
|
148
158
|
const pluginPath = seenPluginIds.get(id);
|
|
149
|
-
throw new Error(colorize.red(`Plugin "id" must be unique. Plugin ${colorize.blue(p.toString())} uses id "${colorize.blue(id)}" already seen in ${colorize.blue(pluginPath)}`));
|
|
159
|
+
throw new Error(logger_1.colorize.red(`Plugin "id" must be unique. Plugin ${logger_1.colorize.blue(p.toString())} uses id "${logger_1.colorize.blue(id)}" already seen in ${logger_1.colorize.blue(pluginPath)}`));
|
|
150
160
|
}
|
|
151
161
|
seenPluginIds.set(id, p.toString());
|
|
152
162
|
const plugin = {
|
|
@@ -165,22 +175,22 @@ export async function resolvePlugins(plugins, configDir = '') {
|
|
|
165
175
|
}
|
|
166
176
|
plugin.rules = {};
|
|
167
177
|
if (pluginModule.rules.oas3) {
|
|
168
|
-
plugin.rules.oas3 = prefixRules(pluginModule.rules.oas3, id);
|
|
178
|
+
plugin.rules.oas3 = (0, utils_2.prefixRules)(pluginModule.rules.oas3, id);
|
|
169
179
|
}
|
|
170
180
|
if (pluginModule.rules.oas2) {
|
|
171
|
-
plugin.rules.oas2 = prefixRules(pluginModule.rules.oas2, id);
|
|
181
|
+
plugin.rules.oas2 = (0, utils_2.prefixRules)(pluginModule.rules.oas2, id);
|
|
172
182
|
}
|
|
173
183
|
if (pluginModule.rules.async2) {
|
|
174
|
-
plugin.rules.async2 = prefixRules(pluginModule.rules.async2, id);
|
|
184
|
+
plugin.rules.async2 = (0, utils_2.prefixRules)(pluginModule.rules.async2, id);
|
|
175
185
|
}
|
|
176
186
|
if (pluginModule.rules.async3) {
|
|
177
|
-
plugin.rules.async3 = prefixRules(pluginModule.rules.async3, id);
|
|
187
|
+
plugin.rules.async3 = (0, utils_2.prefixRules)(pluginModule.rules.async3, id);
|
|
178
188
|
}
|
|
179
189
|
if (pluginModule.rules.arazzo1) {
|
|
180
|
-
plugin.rules.arazzo1 = prefixRules(pluginModule.rules.arazzo1, id);
|
|
190
|
+
plugin.rules.arazzo1 = (0, utils_2.prefixRules)(pluginModule.rules.arazzo1, id);
|
|
181
191
|
}
|
|
182
192
|
if (pluginModule.rules.overlay1) {
|
|
183
|
-
plugin.rules.overlay1 = prefixRules(pluginModule.rules.overlay1, id);
|
|
193
|
+
plugin.rules.overlay1 = (0, utils_2.prefixRules)(pluginModule.rules.overlay1, id);
|
|
184
194
|
}
|
|
185
195
|
}
|
|
186
196
|
if (pluginModule.preprocessors) {
|
|
@@ -194,22 +204,22 @@ export async function resolvePlugins(plugins, configDir = '') {
|
|
|
194
204
|
}
|
|
195
205
|
plugin.preprocessors = {};
|
|
196
206
|
if (pluginModule.preprocessors.oas3) {
|
|
197
|
-
plugin.preprocessors.oas3 = prefixRules(pluginModule.preprocessors.oas3, id);
|
|
207
|
+
plugin.preprocessors.oas3 = (0, utils_2.prefixRules)(pluginModule.preprocessors.oas3, id);
|
|
198
208
|
}
|
|
199
209
|
if (pluginModule.preprocessors.oas2) {
|
|
200
|
-
plugin.preprocessors.oas2 = prefixRules(pluginModule.preprocessors.oas2, id);
|
|
210
|
+
plugin.preprocessors.oas2 = (0, utils_2.prefixRules)(pluginModule.preprocessors.oas2, id);
|
|
201
211
|
}
|
|
202
212
|
if (pluginModule.preprocessors.async2) {
|
|
203
|
-
plugin.preprocessors.async2 = prefixRules(pluginModule.preprocessors.async2, id);
|
|
213
|
+
plugin.preprocessors.async2 = (0, utils_2.prefixRules)(pluginModule.preprocessors.async2, id);
|
|
204
214
|
}
|
|
205
215
|
if (pluginModule.preprocessors.async3) {
|
|
206
|
-
plugin.preprocessors.async3 = prefixRules(pluginModule.preprocessors.async3, id);
|
|
216
|
+
plugin.preprocessors.async3 = (0, utils_2.prefixRules)(pluginModule.preprocessors.async3, id);
|
|
207
217
|
}
|
|
208
218
|
if (pluginModule.preprocessors.arazzo1) {
|
|
209
|
-
plugin.preprocessors.arazzo1 = prefixRules(pluginModule.preprocessors.arazzo1, id);
|
|
219
|
+
plugin.preprocessors.arazzo1 = (0, utils_2.prefixRules)(pluginModule.preprocessors.arazzo1, id);
|
|
210
220
|
}
|
|
211
221
|
if (pluginModule.preprocessors.overlay1) {
|
|
212
|
-
plugin.preprocessors.overlay1 = prefixRules(pluginModule.preprocessors.overlay1, id);
|
|
222
|
+
plugin.preprocessors.overlay1 = (0, utils_2.prefixRules)(pluginModule.preprocessors.overlay1, id);
|
|
213
223
|
}
|
|
214
224
|
}
|
|
215
225
|
if (pluginModule.decorators) {
|
|
@@ -223,22 +233,22 @@ export async function resolvePlugins(plugins, configDir = '') {
|
|
|
223
233
|
}
|
|
224
234
|
plugin.decorators = {};
|
|
225
235
|
if (pluginModule.decorators.oas3) {
|
|
226
|
-
plugin.decorators.oas3 = prefixRules(pluginModule.decorators.oas3, id);
|
|
236
|
+
plugin.decorators.oas3 = (0, utils_2.prefixRules)(pluginModule.decorators.oas3, id);
|
|
227
237
|
}
|
|
228
238
|
if (pluginModule.decorators.oas2) {
|
|
229
|
-
plugin.decorators.oas2 = prefixRules(pluginModule.decorators.oas2, id);
|
|
239
|
+
plugin.decorators.oas2 = (0, utils_2.prefixRules)(pluginModule.decorators.oas2, id);
|
|
230
240
|
}
|
|
231
241
|
if (pluginModule.decorators.async2) {
|
|
232
|
-
plugin.decorators.async2 = prefixRules(pluginModule.decorators.async2, id);
|
|
242
|
+
plugin.decorators.async2 = (0, utils_2.prefixRules)(pluginModule.decorators.async2, id);
|
|
233
243
|
}
|
|
234
244
|
if (pluginModule.decorators.async3) {
|
|
235
|
-
plugin.decorators.async3 = prefixRules(pluginModule.decorators.async3, id);
|
|
245
|
+
plugin.decorators.async3 = (0, utils_2.prefixRules)(pluginModule.decorators.async3, id);
|
|
236
246
|
}
|
|
237
247
|
if (pluginModule.decorators.arazzo1) {
|
|
238
|
-
plugin.decorators.arazzo1 = prefixRules(pluginModule.decorators.arazzo1, id);
|
|
248
|
+
plugin.decorators.arazzo1 = (0, utils_2.prefixRules)(pluginModule.decorators.arazzo1, id);
|
|
239
249
|
}
|
|
240
250
|
if (pluginModule.decorators.overlay1) {
|
|
241
|
-
plugin.decorators.overlay1 = prefixRules(pluginModule.decorators.overlay1, id);
|
|
251
|
+
plugin.decorators.overlay1 = (0, utils_2.prefixRules)(pluginModule.decorators.overlay1, id);
|
|
242
252
|
}
|
|
243
253
|
}
|
|
244
254
|
if (pluginModule.assertions) {
|
|
@@ -249,13 +259,13 @@ export async function resolvePlugins(plugins, configDir = '') {
|
|
|
249
259
|
...plugin,
|
|
250
260
|
};
|
|
251
261
|
}));
|
|
252
|
-
return instances.filter(isDefined);
|
|
262
|
+
return instances.filter(utils_1.isDefined);
|
|
253
263
|
}
|
|
254
|
-
|
|
264
|
+
async function resolveApis({ rawConfig, configPath = '', resolver, }) {
|
|
255
265
|
const { apis = {}, styleguide: styleguideConfig = {} } = rawConfig;
|
|
256
266
|
const resolvedApis = {};
|
|
257
267
|
for (const [apiName, apiContent] of Object.entries(apis || {})) {
|
|
258
|
-
if (apiContent.styleguide?.extends?.some(isNotString)) {
|
|
268
|
+
if (apiContent.styleguide?.extends?.some(utils_1.isNotString)) {
|
|
259
269
|
throw new Error(`Error configuration format not detected in extends value must contain strings`);
|
|
260
270
|
}
|
|
261
271
|
const rawStyleguideConfig = getMergedRawStyleguideConfig(styleguideConfig, apiContent.styleguide);
|
|
@@ -268,27 +278,27 @@ export async function resolveApis({ rawConfig, configPath = '', resolver, }) {
|
|
|
268
278
|
}
|
|
269
279
|
return resolvedApis;
|
|
270
280
|
}
|
|
271
|
-
async function resolveAndMergeNestedStyleguideConfig({ styleguideConfig, configPath = '', resolver = new BaseResolver(), parentConfigPaths = [], extendPaths = [], }) {
|
|
281
|
+
async function resolveAndMergeNestedStyleguideConfig({ styleguideConfig, configPath = '', resolver = new resolve_1.BaseResolver(), parentConfigPaths = [], extendPaths = [], }) {
|
|
272
282
|
if (parentConfigPaths.includes(configPath)) {
|
|
273
283
|
throw new Error(`Circular dependency in config file: "${configPath}"`);
|
|
274
284
|
}
|
|
275
|
-
const plugins = isBrowser
|
|
285
|
+
const plugins = env_1.isBrowser
|
|
276
286
|
? // In browser, we don't support plugins from config file yet
|
|
277
|
-
[defaultPlugin]
|
|
278
|
-
: getUniquePlugins(await resolvePlugins([...(styleguideConfig?.plugins || []), defaultPlugin], path.dirname(configPath)));
|
|
287
|
+
[builtIn_1.defaultPlugin]
|
|
288
|
+
: (0, utils_2.getUniquePlugins)(await resolvePlugins([...(styleguideConfig?.plugins || []), builtIn_1.defaultPlugin], path.dirname(configPath)));
|
|
279
289
|
const pluginPaths = styleguideConfig?.plugins
|
|
280
|
-
?.filter(isString)
|
|
290
|
+
?.filter(utils_1.isString)
|
|
281
291
|
.map((p) => path.resolve(path.dirname(configPath), p));
|
|
282
|
-
const resolvedConfigPath = isAbsoluteUrl(configPath)
|
|
292
|
+
const resolvedConfigPath = (0, ref_utils_1.isAbsoluteUrl)(configPath)
|
|
283
293
|
? configPath
|
|
284
294
|
: configPath && path.resolve(configPath);
|
|
285
295
|
const extendConfigs = await Promise.all(styleguideConfig?.extends?.map(async (presetItem) => {
|
|
286
|
-
if (!isAbsoluteUrl(presetItem) && !path.extname(presetItem)) {
|
|
296
|
+
if (!(0, ref_utils_1.isAbsoluteUrl)(presetItem) && !path.extname(presetItem)) {
|
|
287
297
|
return resolvePreset(presetItem, plugins);
|
|
288
298
|
}
|
|
289
|
-
const pathItem = isAbsoluteUrl(presetItem)
|
|
299
|
+
const pathItem = (0, ref_utils_1.isAbsoluteUrl)(presetItem)
|
|
290
300
|
? presetItem
|
|
291
|
-
: isAbsoluteUrl(configPath)
|
|
301
|
+
: (0, ref_utils_1.isAbsoluteUrl)(configPath)
|
|
292
302
|
? new URL(presetItem, configPath).href
|
|
293
303
|
: path.resolve(path.dirname(configPath), presetItem);
|
|
294
304
|
const extendedStyleguideConfig = await loadExtendStyleguideConfig(pathItem, resolver);
|
|
@@ -300,7 +310,7 @@ async function resolveAndMergeNestedStyleguideConfig({ styleguideConfig, configP
|
|
|
300
310
|
extendPaths,
|
|
301
311
|
});
|
|
302
312
|
}) || []);
|
|
303
|
-
const { plugins: mergedPlugins = [], ...styleguide } = mergeExtends([
|
|
313
|
+
const { plugins: mergedPlugins = [], ...styleguide } = (0, utils_2.mergeExtends)([
|
|
304
314
|
...extendConfigs,
|
|
305
315
|
{
|
|
306
316
|
...styleguideConfig,
|
|
@@ -312,37 +322,37 @@ async function resolveAndMergeNestedStyleguideConfig({ styleguideConfig, configP
|
|
|
312
322
|
]);
|
|
313
323
|
return {
|
|
314
324
|
...styleguide,
|
|
315
|
-
extendPaths: styleguide.extendPaths?.filter((path) => path && !isAbsoluteUrl(path)),
|
|
316
|
-
plugins: getUniquePlugins(mergedPlugins),
|
|
325
|
+
extendPaths: styleguide.extendPaths?.filter((path) => path && !(0, ref_utils_1.isAbsoluteUrl)(path)),
|
|
326
|
+
plugins: (0, utils_2.getUniquePlugins)(mergedPlugins),
|
|
317
327
|
recommendedFallback: styleguideConfig?.recommendedFallback,
|
|
318
328
|
doNotResolveExamples: styleguideConfig?.doNotResolveExamples,
|
|
319
329
|
};
|
|
320
330
|
}
|
|
321
|
-
|
|
331
|
+
async function resolveStyleguideConfig(opts) {
|
|
322
332
|
const resolvedStyleguideConfig = await resolveAndMergeNestedStyleguideConfig(opts);
|
|
323
333
|
return {
|
|
324
334
|
...resolvedStyleguideConfig,
|
|
325
335
|
rules: resolvedStyleguideConfig.rules && groupStyleguideAssertionRules(resolvedStyleguideConfig),
|
|
326
336
|
};
|
|
327
337
|
}
|
|
328
|
-
|
|
329
|
-
const { pluginId, configName } = parsePresetName(presetName);
|
|
338
|
+
function resolvePreset(presetName, plugins) {
|
|
339
|
+
const { pluginId, configName } = (0, utils_2.parsePresetName)(presetName);
|
|
330
340
|
const plugin = plugins.find((p) => p.id === pluginId);
|
|
331
341
|
if (!plugin) {
|
|
332
|
-
throw new Error(`Invalid config ${colorize.red(presetName)}: plugin ${pluginId} is not included.`);
|
|
342
|
+
throw new Error(`Invalid config ${logger_1.colorize.red(presetName)}: plugin ${pluginId} is not included.`);
|
|
333
343
|
}
|
|
334
344
|
const preset = plugin.configs?.[configName];
|
|
335
345
|
if (!preset) {
|
|
336
346
|
throw new Error(pluginId
|
|
337
|
-
? `Invalid config ${colorize.red(presetName)}: plugin ${pluginId} doesn't export config with name ${configName}.`
|
|
338
|
-
: `Invalid config ${colorize.red(presetName)}: there is no such built-in config.`);
|
|
347
|
+
? `Invalid config ${logger_1.colorize.red(presetName)}: plugin ${pluginId} doesn't export config with name ${configName}.`
|
|
348
|
+
: `Invalid config ${logger_1.colorize.red(presetName)}: there is no such built-in config.`);
|
|
339
349
|
}
|
|
340
350
|
return preset;
|
|
341
351
|
}
|
|
342
352
|
async function loadExtendStyleguideConfig(filePath, resolver) {
|
|
343
353
|
try {
|
|
344
354
|
const { parsed } = (await resolver.resolveDocument(null, filePath));
|
|
345
|
-
const rawConfig = transformConfig(parsed);
|
|
355
|
+
const rawConfig = (0, utils_2.transformConfig)(parsed);
|
|
346
356
|
if (!rawConfig.styleguide) {
|
|
347
357
|
throw new Error(`Styleguide configuration format not detected: "${filePath}"`);
|
|
348
358
|
}
|
|
@@ -355,7 +365,7 @@ async function loadExtendStyleguideConfig(filePath, resolver) {
|
|
|
355
365
|
function getMergedRawStyleguideConfig(rootStyleguideConfig, apiStyleguideConfig) {
|
|
356
366
|
const resultLint = {
|
|
357
367
|
...rootStyleguideConfig,
|
|
358
|
-
...pickDefined(apiStyleguideConfig),
|
|
368
|
+
...(0, utils_1.pickDefined)(apiStyleguideConfig),
|
|
359
369
|
rules: { ...rootStyleguideConfig?.rules, ...apiStyleguideConfig?.rules },
|
|
360
370
|
oas2Rules: { ...rootStyleguideConfig?.oas2Rules, ...apiStyleguideConfig?.oas2Rules },
|
|
361
371
|
oas3_0Rules: { ...rootStyleguideConfig?.oas3_0Rules, ...apiStyleguideConfig?.oas3_0Rules },
|
|
@@ -447,18 +457,17 @@ function groupStyleguideAssertionRules({ rules, plugins, }) {
|
|
|
447
457
|
return transformedRules;
|
|
448
458
|
}
|
|
449
459
|
function registerCustomAssertions(plugins, assertion) {
|
|
450
|
-
for (const field of keysOf(assertion.assertions)) {
|
|
460
|
+
for (const field of (0, utils_1.keysOf)(assertion.assertions)) {
|
|
451
461
|
const [pluginId, fn] = field.split('/');
|
|
452
462
|
if (!pluginId || !fn)
|
|
453
463
|
continue;
|
|
454
464
|
const plugin = plugins.find((plugin) => plugin.id === pluginId);
|
|
455
465
|
if (!plugin) {
|
|
456
|
-
throw Error(colorize.red(`Plugin ${colorize.blue(pluginId)} isn't found.`));
|
|
466
|
+
throw Error(logger_1.colorize.red(`Plugin ${logger_1.colorize.blue(pluginId)} isn't found.`));
|
|
457
467
|
}
|
|
458
468
|
if (!plugin.assertions || !plugin.assertions[fn]) {
|
|
459
|
-
throw Error(`Plugin ${colorize.red(pluginId)} doesn't export assertions function with name ${colorize.red(fn)}.`);
|
|
469
|
+
throw Error(`Plugin ${logger_1.colorize.red(pluginId)} doesn't export assertions function with name ${logger_1.colorize.red(fn)}.`);
|
|
460
470
|
}
|
|
461
|
-
asserts[field] = buildAssertCustomFunction(plugin.assertions[fn]);
|
|
471
|
+
asserts_1.asserts[field] = (0, asserts_1.buildAssertCustomFunction)(plugin.assertions[fn]);
|
|
462
472
|
}
|
|
463
473
|
}
|
|
464
|
-
//# sourceMappingURL=config-resolvers.js.map
|
package/lib/config/config.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { SpecVersion, SpecMajorVersion } from '../oas-types
|
|
2
|
-
import type { NormalizedProblem } from '../walk
|
|
3
|
-
import type { Oas2RuleSet, Oas3RuleSet, Async3RuleSet, Arazzo1RuleSet, Overlay1RuleSet } from '../oas-types
|
|
4
|
-
import type { NodeType } from '../types
|
|
5
|
-
import type { DecoratorConfig, Plugin, PreprocessorConfig, ResolveConfig, ResolvedApi, ResolvedConfig, ResolvedStyleguideConfig, RuleConfig, RuleSettings, Telemetry, ThemeRawConfig } from './types
|
|
1
|
+
import { SpecVersion, SpecMajorVersion } from '../oas-types';
|
|
2
|
+
import type { NormalizedProblem } from '../walk';
|
|
3
|
+
import type { Oas2RuleSet, Oas3RuleSet, Async3RuleSet, Arazzo1RuleSet, Overlay1RuleSet } from '../oas-types';
|
|
4
|
+
import type { NodeType } from '../types';
|
|
5
|
+
import type { DecoratorConfig, Plugin, PreprocessorConfig, Region, ResolveConfig, ResolvedApi, ResolvedConfig, ResolvedStyleguideConfig, RuleConfig, RuleSettings, Telemetry, ThemeRawConfig } from './types';
|
|
6
6
|
export declare const IGNORE_FILE = ".redocly.lint-ignore.yaml";
|
|
7
7
|
export declare class StyleguideConfig {
|
|
8
8
|
rawConfig: ResolvedStyleguideConfig;
|
|
@@ -44,8 +44,10 @@ export declare class Config {
|
|
|
44
44
|
styleguide: StyleguideConfig;
|
|
45
45
|
resolve: ResolveConfig;
|
|
46
46
|
licenseKey?: string;
|
|
47
|
+
region?: Region;
|
|
47
48
|
theme: ThemeRawConfig;
|
|
49
|
+
organization?: string;
|
|
50
|
+
files: string[];
|
|
48
51
|
telemetry?: Telemetry;
|
|
49
52
|
constructor(rawConfig: ResolvedConfig, configFile?: string | undefined);
|
|
50
53
|
}
|
|
51
|
-
//# sourceMappingURL=config.d.ts.map
|