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

Allow including external yaml files in .meshrc.yaml #1412

Closed
chompy18 opened this issue Jan 13, 2021 · 3 comments
Closed

Allow including external yaml files in .meshrc.yaml #1412

chompy18 opened this issue Jan 13, 2021 · 3 comments
Labels

Comments

@chompy18
Copy link

When using transforms, the .meshrc file gets really big and hard to follow.
Being able to break the meshrc into readable chunks .

Talking to @dotansimha over chat, he suggested:
I think we can eventually add it. YAML does support partials, but not from external files.
Maybe we can try to do that as part of our parsing process.

@ardatan
Copy link
Owner

ardatan commented Jan 13, 2021

Thanks for the suggestion!
@dotansimha This can be done on cosmiconfig side so other projects using cosmiconfig like graphql-config or graphql-codegen can support that.

@ardatan ardatan changed the title Allow including external yaml files in .mashrc.yaml Allow including external yaml files in .meshrc.yaml Jan 13, 2021
@chompy18
Copy link
Author

it would be great if we could:

serve: ./serve-config.yaml
transforms:
  - rename: ./rename-transforms.yaml
  - extend: ./extend-transforms.yaml
  - cache: ./cache-transforms.yaml

@ardatan
Copy link
Owner

ardatan commented Feb 18, 2022

This is implemented in the latest version but we haven't documented yet so you can include yaml files like;

serve: !include ./serve-config.yaml
transforms:
  - rename: !include./rename-transforms.yaml
  - extend: !include ./extend-transforms.yaml
  - cache: !include ./cache-transforms.yaml

@ardatan ardatan closed this as completed Feb 18, 2022
@ardatan ardatan reopened this Feb 18, 2022
@theguild-bot theguild-bot mentioned this issue Aug 11, 2022
@ardatan ardatan closed this as completed Mar 29, 2023
@theguild-bot theguild-bot mentioned this issue Sep 28, 2023
This was referenced Apr 30, 2024
This was referenced May 7, 2024
klippx pushed a commit to klippx/graphql-mesh that referenced this issue Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants