{"name":"@envelop/validation-cache","version":"6.0.0-alpha-20221013150034-9758afb9","sideEffects":false,"peerDependencies":{"@envelop/core":"4.0.0-alpha-20221013150034-9758afb9","graphql":"^14.0.0 || ^15.0.0 || ^16.0.0"},"dependencies":{"lru-cache":"^6.0.0","tslib":"^2.4.0"},"repository":{"type":"git","url":"git+https://github.com/n1ru4l/envelop.git","directory":"packages/plugins/validation-cache"},"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/validation-cache`\n\nThis plugins adds simple LRU caching to your `validate`, to improve performance by caching the validation result.\n\nThis plugins improves performance of validating by ~50% (based on benchmarks).\n\n## Getting Started\n\n```\nyarn add @envelop/validation-cache\n```\n\n## Usage Example\n\n```ts\nimport { parse, validate, specifiedRules, execute, subscribe } from 'graphql'\nimport { envelop, useEngine } from '@envelop/core'\nimport { useValidationCache } from '@envelop/validation-cache'\n\nconst getEnveloped = envelop({\n  plugins: [\n    useEngine({ parse, validate, specifiedRules, execute, subscribe }),\n    // ... other plugins ...\n    useValidationCache({\n      // options goes here\n    })\n  ]\n})\n```\n\n### API Reference\n\n#### `cache`\n\nSet this to pass in a cache instance. By default a new LRU cache is created using default `max` and `ttl`.\n","readmeFilename":"README.md","gitHead":"9758afb9d1e1d4037cd7b7f0f9171d1760a5840f","description":"This plugins adds simple LRU caching to your `validate`, to improve performance by caching the validation result.","bugs":{"url":"https://github.com/n1ru4l/envelop/issues"},"homepage":"https://github.com/n1ru4l/envelop#readme","_id":"@envelop/validation-cache@6.0.0-alpha-20221013150034-9758afb9","_nodeVersion":"18.10.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-bCcYvoGNZi5Tbn6AbHi+sjx/DHkDgklUS6E3lsFleJrNScsnx5DV8+eyo12rKo5r1+uDzILACcfnDDfHIU6cCg==","shasum":"3c17e5b0a2591469e6648b80c144a2ead2d2d48f","tarball":"http://registry-npm.ywwl.com/@envelop/validation-cache/download/@envelop/validation-cache-6.0.0-alpha-20221013150034-9758afb9.tgz","fileCount":7,"unpackedSize":6561,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFksPBDdo1rzTTlMoqEAI5KlqLomARSXRSudihC/PIk6AiBMhFP1lWGGxgrZqaQS+Pff6GaaS1s0CmYiS4kLi4E+GA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjSChDACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmp9uA/+Mja76FV4ohJLijq0b/NCGPl2sndZ20jTB/w/+KsbTU+9NWyN\r\nIS+SUi/AeKcPq+oU3G8+GFf+srm5kkMg77mtsM/8ccVmTfsyg15H9yMp6A2C\r\nWESY2fzyA50jfcQiDNQ+a8Mzq4ZuNS95beZQZGB86nFCczdGzg5DnX97Us+G\r\n5GMa3u6bS/uW+EyC1cqd/PkCDaPEsQ6LsuHEMY7iMAG9NaxqkbHxFa4ascCX\r\n2A4RnwUnj5g0aBeYR68b9edOFS1S2mWdfWE3uHh8d+gFQJRrbHwBvvcjN7G4\r\nqXMWRKYgM0lApJJ4G70tWqOBKRsKt/sEiHk7iikfhGD3Gs/6BEInCcds+9+5\r\n70Xy8e2m8okv7BQD/3MKMpX1Q4/2q6r+AYQhFDyxOIJW1C1DG20IfldacJH1\r\npGNk+mVUVeZE1QVshXWfEWwZEJMAI8cnMhZpCB2z1T6zyRbeexL7gucqKwAa\r\nqeGpiKsMf0a5S/xhMe2JB2qCqnfa8Zndqi3Sj05OGURklvNgPXY0hNFBd59P\r\nU/Bhj+0xgBQ3kBmGdZ9K9ygJ/3NStYfPEMAMDSfQh84pNbSi286UC+NkQU+y\r\nPDfpRRFfVbC5wdDCeqT6TVwM8c7KrUIQHqfb3WJKW8FDQWYNz/ucoAU0fWeO\r\nEkKRLzxyzTeR9BBzC4ZIlYrhRBm9qv21Ojg=\r\n=UCez\r\n-----END PGP SIGNATURE-----\r\n","size":1939,"noattachment":false,"key":"/@envelop/validation-cache/-/@envelop/validation-cache-6.0.0-alpha-20221013150034-9758afb9.tgz"},"_npmUser":{"name":"dotansimha","email":"dotansimha@gmail.com"},"directories":{},"maintainers":[{"name":"dotansimha","email":"dotansimha@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/validation-cache_6.0.0-alpha-20221013150034-9758afb9_1665673283744_0.9141296488117465"},"_hasShrinkwrap":false,"publish_time":1665673283899,"_cnpm_publish_time":1665673283899,"dist-tags":{"alpha":"11.0.2-alpha-20261126100851-58d9782f151a975e802f1a545a315263d8d886a7","latest":"11.0.1","rc":"11.0.2-rc-20261124205929-9595907fc2bef8a397343bd288fef4685ab9f508"}}