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

support new config option mappersRelativeTargetDir #345

Merged
merged 5 commits into from
Nov 20, 2024

Conversation

HunterLarco
Copy link
Contributor

By default, mappers must be siblings with the schema they represent. For example, if the schema file is /path/to/schema.graphql, the mapper file is /path/to/schema.mappers.ts. This extension allows mappers to reside in a different directory relative to the schema file using the pattern <schemaPath>/<mappersRelativeTargetDir>/<schemaName><mappersFileExtension>. This is useful for users which prefer to locate mappers in their own directory rather than interspliced with the schema files.

Testing

  • unit tests in typescript-resolver-files are passing
  • e2e tests are passing. Note that I've updated a pre-existing e2e test which already tests every mapper option. I've added this new option to the test and validate that output looks as expected.
  • I've used a local build of this change in my own project and validated that the generated output builds and operates as expected.

Copy link

changeset-bot bot commented Nov 14, 2024

⚠️ No Changeset found

Latest commit: 1d47972

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@HunterLarco HunterLarco marked this pull request as ready for review November 14, 2024 13:49
Copy link
Owner

@eddeee888 eddeee888 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@eddeee888 eddeee888 merged commit 9543af7 into eddeee888:master Nov 20, 2024
13 checks passed
@eddeee888 eddeee888 mentioned this pull request Nov 20, 2024
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

Successfully merging this pull request may close these issues.

2 participants