{"name":"@envelop/disable-introspection","version":"4.0.0-alpha-20220915130636-f58d2400","sideEffects":false,"peerDependencies":{"@envelop/core":"3.0.0-alpha-20220915130636-f58d2400","graphql":"^14.0.0 || ^15.0.0 || ^16.0.0"},"dependencies":{"tslib":"^2.4.0"},"repository":{"type":"git","url":"git+https://github.com/n1ru4l/envelop.git","directory":"packages/plugins/disable-introspection"},"author":{"name":"Dotan Simha","email":"dotansimha@gmail.com"},"license":"MIT","main":"cjs/index.js","module":"esm/index.js","typings":"typings/index.d.ts","typescript":{"definition":"typings/index.d.ts"},"type":"module","exports":{".":{"require":{"types":"./typings/index.d.cts","default":"./cjs/index.js"},"import":{"types":"./typings/index.d.ts","default":"./esm/index.js"},"default":{"types":"./typings/index.d.ts","default":"./esm/index.js"}},"./*":{"require":{"types":"./typings/*.d.cts","default":"./cjs/*.js"},"import":{"types":"./typings/*.d.ts","default":"./esm/*.js"},"default":{"types":"./typings/*.d.ts","default":"./esm/*.js"}},"./package.json":"./package.json"},"readme":"## `@envelop/disable-introspection`\n\nThis plugin injects the `NoSchemaIntrospectionCustomRule` validation rule exported from the `graphql` module to the validation phase for disabling introspection.\n\n## Getting Started\n\n```\nyarn add @envelop/disable-introspection\n```\n\n## Usage Example\n\n```ts\nimport { parse, validate, execute, subscribe } from 'graphql'\nimport { envelop } from '@envelop/core'\nimport { useDisableIntrospection } from '@envelop/disable-introspection'\n\nconst getEnveloped = envelop({\n  parse,\n  validate,\n  execute,\n  subscribe,\n  plugins: [useDisableIntrospection()]\n})\n```\n\n## Optional configuration\n\nThe plugin optionally accepts a configuration object:\n\n```\n{\n  disableIf?: ({context, params}) => boolean\n}\n```\n\n- `disableIf`: A function that allow you to evaluate the need to disable introspection, based on the incoming operation. If introspection needs to be disabled/enabled based on the dynamic parameter (GraphQL operation, or, incoming request/headers), use this function to determine when introspection needs to be disabled. Return true for disabling the introspection for the incoming operation, or false to allow introspection.\n","readmeFilename":"README.md","gitHead":"f58d24000c202ad0c9338beab1c832f0b1c382be","description":"This plugin injects the `NoSchemaIntrospectionCustomRule` validation rule exported from the `graphql` module to the validation phase for disabling introspection.","bugs":{"url":"https://github.com/n1ru4l/envelop/issues"},"homepage":"https://github.com/n1ru4l/envelop#readme","_id":"@envelop/disable-introspection@4.0.0-alpha-20220915130636-f58d2400","_nodeVersion":"18.9.0","_npmVersion":"8.19.1","dist":{"integrity":"sha512-IiRpaosmPV/AmT3dLn8AYPwMo/Hd3uECvJTmCKJ4eGPaT8XNZrOOHR7WIFTFloWBzAnmNtdjcO1gbAwLOfrfYQ==","shasum":"874a0fde24ea989aaaf48b2fc8c76c978b6411e5","tarball":"http://registry-npm.ywwl.com/@envelop/disable-introspection/download/@envelop/disable-introspection-4.0.0-alpha-20220915130636-f58d2400.tgz","fileCount":7,"unpackedSize":4560,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCtR5uu+w8/les0v7fPkk+iKnT3edJccBx43csHOwdwawIhAKkNHjkGt8r9dQGCxCC9mYnGJo08CO6NLD+gvi0NaL3N"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjIyN/ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqUtg//fuJhPlqZ4Nnbl8MU2qdm5JT/vHoBNJOLo0CFiwPhwngsVwSQ\r\nEjsOOPkWLjjQ3g5dNi1Lw6jSCe1BusuE3Gc5ZsMyufeQLpLeyXqYKE0sZlLv\r\nbvZlnwC9vu+J/cjxluoiuLAT9ytiqh0wL/8sYfcSQP/0zDwFxj2bl+O1fiJ+\r\npK56gW7d4+PpfdjUPMrTs6GX3jkgvZ9ACPqv+ac+rbhsoBnf05AIiwGaTRS+\r\nXALozEYjkie22VjaqT0Om1TzN7cW0bCZn7S80OVS/aYFJe8HzZmna2ewao+2\r\nLYNrIAMF1hR7rgY/GC5aikVEV0h/zumv2kSxVU+cfYW3P03YXy1TLq8ObwpG\r\nBQTnGUVXlQpmyVAqCTB0g96FQRwaRYDf21kmqmG8fNnqCLlktkc5rYfHCImW\r\n10l1mTArFWFe8TUyfnRG0ntvQ6EBbgqB7KZqpKE29WR3LxtWIklKy1epND19\r\n8A1XZispeFNTT+9wnzGGlRydA+/J8yvEukkp3WbrmNTIfmWr2mJZvWR2faYZ\r\nKnDDXV4A4V2YIcjDxBedeB4+riP96AxjNo266YYBNVfg3YX9w0uXEDc5bXCC\r\nFiCT0I/in9MqBMpeLcyZR0ozh6tju4HyRx67aFL5gGu6WkXqPZSIKCkbPXqd\r\nsn4M89Gn7s0hBrs27xedYdeBe+EuwXyRkNk=\r\n=u8DE\r\n-----END PGP SIGNATURE-----\r\n","size":1559,"noattachment":false,"key":"/@envelop/disable-introspection/-/@envelop/disable-introspection-4.0.0-alpha-20220915130636-f58d2400.tgz"},"_npmUser":{"name":"dotansimha","email":"dotansimha@gmail.com"},"directories":{},"maintainers":[{"name":"dotansimha","email":"dotansimha@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/disable-introspection_4.0.0-alpha-20220915130636-f58d2400_1663247230934_0.03140920572811634"},"_hasShrinkwrap":false,"publish_time":1663247231160,"_cnpm_publish_time":1663247231160,"dist-tags":{"alpha":"10.0.0-alpha-20261019231601-b21e6cedc1a444383d9ce69fe6180f5b4ff67120","latest":"10.0.0","rc":"10.0.0-rc-20261022165416-7c29decb398764e6ac3915e1c539c478cbf19237"}}