n1ru4l / envelop

Envelop is a lightweight library allowing developers to easily develop, share, collaborate and extend their GraphQL execution layer. Envelop is the missing GraphQL plugin system.
https://envelop.dev
MIT License
785 stars 127 forks source link

Add `useValidationRule()` plugin #2215

Closed benjie closed 5 months ago

benjie commented 5 months ago

Description

As discussed with @n1ru4l, this adds the useValidationRule() plugin, which can be used to add a validation rule.

Type of change

Please delete options that are not relevant.

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

Checklist:

Further comments

The newrelic tests are failing locally; I think this is unrelated given how trivial the function I've added is.

changeset-bot[bot] commented 5 months ago

🦋 Changeset detected

Latest commit: 1f56053b0e667e0fde440e2063d242a32ce3ed2f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package | Name | Type | | ------------- | ----- | | @envelop/core | Patch |

Not sure what this means? Click here to learn what changesets are.

[Click here if you're a maintainer who wants to add another changeset to this PR](https://github.com/benjie/envelop/new/validation-rule?filename=.changeset/late-socks-protect.md&value=---%0A%22website%22%3A%20patch%0A%22%40envelop%2Fcore%22%3A%20patch%0A---%0A%0AAdd%20%60useValidationRule()%60%20plugin%0A)

benjie commented 5 months ago

I do not know how to address these test failures. I do not think it's related to my changes?