Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bundle() not resolving all $ref #161

Open
joelfoliveira opened this issue Feb 25, 2021 · 0 comments
Open

Bundle() not resolving all $ref #161

joelfoliveira opened this issue Feb 25, 2021 · 0 comments

Comments

@joelfoliveira
Copy link

joelfoliveira commented Feb 25, 2021

When referencing the same component from other different components, Bundle() won't resolve the references correctly.

In this example:
ApiReferences

The bundled output contains a external reference in UserValues to AssociationContext:

components:
  schemas:
    User.Context:
      type: object
      properties:
        values:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
                description: Universal unique identifier of product property value.
                format: uuid
                example: dae18b3a-c5fc-4dc3-a53e-64c905d1f97b
              associationContext:
                type: array
                items:
                  $ref: >-
                    #/components/schemas/User.Context/properties/associationContext/items

API Samples:
API
UserContext
UserValues
AssociationContext

Results
Obtained
Expected

By changing UserValues to reference a duplicate of AssociationContext (UserValuesAssociationContext) the Bundle() works correctly.
ApiReferencesWorkaround

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant