Improve validation of `URLPathTemplate` and `JSONSelection` strings passed to `@source{Type,Field}` directives
Follow-up to #2910.
This work is not finished because we ultimately want to validate that the variables used by URLPathTemplate strings and the output shapes of JSONSelection strings match the available field and argument names.
This PR adds parsers for the two syntaxes and tests of those parsers, which allows us to validate the strings have the expected syntax, even if we're not validating semantics yet.
As another TODO, when we use JSONSelection for body parameters, it's the input shape of the selection that needs to be validated, rather than the output shape, so getSelectionOutputShape may not be sufficient.
⚠️ No Changeset found
Latest commit: 0fc0d11750068325bd29ab23007696c19f0d5bc1
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
This pull request is automatically built and testable in CodeSandbox.
To see build info of the built libraries, click here or the icon next to each commit SHA.