{"_id":"fast-ignore","_rev":"6-cb1217d30afa57d2dc4e3084a51b330a","name":"fast-ignore","dist-tags":{"latest":"2.0.0"},"versions":{"1.0.0":{"name":"fast-ignore","version":"1.0.0","keywords":["fast","gitignore","dotignore","ignore"],"_id":"fast-ignore@1.0.0","maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"homepage":"https://github.com/fabiospampinato/fast-ignore#readme","bugs":{"url":"https://github.com/fabiospampinato/fast-ignore/issues"},"dist":{"shasum":"012fbbe001e983803a798c982ff9b5b324330757","tarball":"https://registry.npmjs.org/fast-ignore/-/fast-ignore-1.0.0.tgz","fileCount":34,"integrity":"sha512-0lvNdNv0hjkJRET+ZK3QGpuo26STHrfc4vFj/wekw8vBQBceUykYs8VpQJzrIx4awNsL1zf2aV3U2x1DEr5Vqw==","signatures":[{"sig":"MEUCIQDLzg/wFDYE9iFyFMp8IKc1YSecbDVghvkQv1OgDKq46QIgFxqzT5u48YZm6isuBLucvfcxyWIHsOQCnvdXwFzRyfs=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":30155},"main":"dist/index.js","type":"module","types":"./dist/index.d.ts","exports":"./dist/index.js","gitHead":"4784e43b4f014da906d3414e974475708b56a46b","scripts":{"test":"tsex test","clean":"tsex clean","compile":"tsex compile","benchmark":"tsex benchmark","test:watch":"tsex test --watch","compile:watch":"tsex compile --watch","prepublishOnly":"tsex prepare","benchmark:watch":"tsex benchmark --watch","benchmark:prepare":"cd tasks && git clone https://github.com/babel/babel.git"},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"repository":{"url":"git+https://github.com/fabiospampinato/fast-ignore.git","type":"git"},"_npmVersion":"10.2.3","description":"A fast parser and processor for .gitignore files.","directories":{},"_nodeVersion":"18.19.0","dependencies":{"grammex":"^3.1.2"},"_hasShrinkwrap":false,"devDependencies":{"fava":"^0.3.1","tsex":"^3.0.1","benchloop":"^2.1.1","typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/fast-ignore_1.0.0_1702084323124_0.6478590541438569","host":"s3://npm-registry-packages"}},"1.1.0":{"name":"fast-ignore","version":"1.1.0","keywords":["fast","gitignore","dotignore","ignore"],"_id":"fast-ignore@1.1.0","maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"homepage":"https://github.com/fabiospampinato/fast-ignore#readme","bugs":{"url":"https://github.com/fabiospampinato/fast-ignore/issues"},"dist":{"shasum":"ed8dd8ea86b5751901f98eabfc2a64582acd7336","tarball":"https://registry.npmjs.org/fast-ignore/-/fast-ignore-1.1.0.tgz","fileCount":34,"integrity":"sha512-eqNU6dqXrIFoW1nbRrbEbsaAkQiNDeGpPtuwLyNuBtf6p8RfLPLQfOxp6ZZjBG7SNmcqoE5RBMvTedUQKtwifQ==","signatures":[{"sig":"MEUCIQCiNKBSx7dwJ3YGwhNoCAhRNmvx94ZaAoNSRpiviny5jwIgMb+FLwtDKuioH2xwVWPomPMEvcI2JqwbiiWmCvW19IY=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":34172},"main":"dist/index.js","type":"module","types":"./dist/index.d.ts","exports":"./dist/index.js","gitHead":"d98fdb2fd320fc5defe5d63f1d76d75791a25729","scripts":{"test":"tsex test","clean":"tsex clean","compile":"tsex compile","benchmark":"tsex benchmark","test:watch":"tsex test --watch","compile:watch":"tsex compile --watch","prepublishOnly":"tsex prepare","benchmark:watch":"tsex benchmark --watch","benchmark:prepare":"cd tasks && git clone https://github.com/babel/babel.git"},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"repository":{"url":"git+https://github.com/fabiospampinato/fast-ignore.git","type":"git"},"_npmVersion":"10.2.3","description":"A fast parser and processor for .gitignore files.","directories":{},"_nodeVersion":"18.19.0","dependencies":{"grammex":"^3.1.2"},"_hasShrinkwrap":false,"devDependencies":{"fava":"^0.3.1","tsex":"^3.0.1","benchloop":"^2.1.1","typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/fast-ignore_1.1.0_1702137684058_0.8248648296928676","host":"s3://npm-registry-packages"}},"1.1.1":{"name":"fast-ignore","version":"1.1.1","keywords":["fast","gitignore","dotignore","ignore"],"_id":"fast-ignore@1.1.1","maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"homepage":"https://github.com/fabiospampinato/fast-ignore#readme","bugs":{"url":"https://github.com/fabiospampinato/fast-ignore/issues"},"dist":{"shasum":"5aad9906d5287819c2d853e79485c6f4a75876a1","tarball":"https://registry.npmjs.org/fast-ignore/-/fast-ignore-1.1.1.tgz","fileCount":34,"integrity":"sha512-Gnvido88waUVtlDv/6VBeXv0TAlQK5lheknMwzHx9948B7uOFjyyLXsYBXixDScEXJB5fMjy4G1OOTH59VKvUA==","signatures":[{"sig":"MEQCIDc6Rk6spZ0qFeVyiFJ7jjWz/xCAAqqW+qt2Y2klMi+UAiBGP/wDNwOASMEr09IMO35TW37OjJiB94QNR5+K1SmPWA==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":34506},"main":"dist/index.js","type":"module","types":"./dist/index.d.ts","exports":"./dist/index.js","gitHead":"9f9615fe0bf2b2ff207651776ad0e003c6f18630","scripts":{"test":"tsex test","clean":"tsex clean","compile":"tsex compile","benchmark":"tsex benchmark","test:watch":"tsex test --watch","compile:watch":"tsex compile --watch","prepublishOnly":"tsex prepare","benchmark:watch":"tsex benchmark --watch","benchmark:prepare":"cd tasks && git clone https://github.com/babel/babel.git"},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"repository":{"url":"git+https://github.com/fabiospampinato/fast-ignore.git","type":"git"},"_npmVersion":"10.2.3","description":"A fast parser and processor for .gitignore files.","directories":{},"_nodeVersion":"18.19.0","dependencies":{"grammex":"^3.1.2"},"_hasShrinkwrap":false,"devDependencies":{"fava":"^0.3.1","tsex":"^3.0.1","benchloop":"^2.1.1","typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/fast-ignore_1.1.1_1702140323126_0.06545635757862756","host":"s3://npm-registry-packages"}},"1.1.2":{"name":"fast-ignore","version":"1.1.2","keywords":["fast","gitignore","dotignore","ignore"],"_id":"fast-ignore@1.1.2","maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"homepage":"https://github.com/fabiospampinato/fast-ignore#readme","bugs":{"url":"https://github.com/fabiospampinato/fast-ignore/issues"},"dist":{"shasum":"d7a5acfcf7f5c7f40fafad68f8b5c9530ba79ff6","tarball":"https://registry.npmjs.org/fast-ignore/-/fast-ignore-1.1.2.tgz","fileCount":34,"integrity":"sha512-7eHBVK0jd28rmNUDQrYxkFxGUfFSPRUQf2ZrB63mrTnaerHKfOoS26r4sedKYw8LIKo+fFltzknX5R0PKRbtGg==","signatures":[{"sig":"MEYCIQC+y4hOqj+tbcC88C7VZyEPZkMEF8hqfuL6dpBC9PIjvgIhALVSKKeLUVVWEkHLPxtcjUdZVY8Y9kbLZKBR3+OdSubC","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":34665},"main":"dist/index.js","type":"module","types":"./dist/index.d.ts","exports":"./dist/index.js","gitHead":"772ddbf2fc33e5d76386c90e0181639d6b386efe","scripts":{"test":"tsex test","clean":"tsex clean","compile":"tsex compile","benchmark":"tsex benchmark","test:watch":"tsex test --watch","compile:watch":"tsex compile --watch","prepublishOnly":"tsex prepare","benchmark:watch":"tsex benchmark --watch","benchmark:prepare":"cd tasks && git clone https://github.com/babel/babel.git"},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"repository":{"url":"git+https://github.com/fabiospampinato/fast-ignore.git","type":"git"},"_npmVersion":"10.2.3","description":"A fast parser and processor for .gitignore files.","directories":{},"_nodeVersion":"18.19.0","dependencies":{"grammex":"^3.1.2"},"_hasShrinkwrap":false,"devDependencies":{"fava":"^0.3.1","tsex":"^3.0.1","benchloop":"^2.1.1","typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/fast-ignore_1.1.2_1711658768542_0.4180855639753598","host":"s3://npm-registry-packages"}},"1.1.3":{"name":"fast-ignore","version":"1.1.3","keywords":["fast","gitignore","dotignore","ignore"],"_id":"fast-ignore@1.1.3","maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"homepage":"https://github.com/fabiospampinato/fast-ignore#readme","bugs":{"url":"https://github.com/fabiospampinato/fast-ignore/issues"},"dist":{"shasum":"c127e17bf115d1d195af942464b6e6bf1fdd9bd2","tarball":"https://registry.npmjs.org/fast-ignore/-/fast-ignore-1.1.3.tgz","fileCount":34,"integrity":"sha512-xTo4UbrOKfEQgOFlPaqFScodTV/Wf3KATEqCZZSMh6OP4bcez0lTsqww3n3/Fve1q9u0jmfDP0q0nOhH4POZEg==","signatures":[{"sig":"MEYCIQD/2hUyhrNaUFFWWGE+9pLbUcMFjTF53WgecraWYb05/AIhAOTb2Ur+RBnEiTTgZrT6yP3/mhPeP3JB4z2ynGYUnXQJ","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":37433},"main":"dist/index.js","type":"module","types":"./dist/index.d.ts","exports":"./dist/index.js","gitHead":"aae8d3a7a1283568c974ac80ac6a731b4ace47a8","scripts":{"test":"tsex test","clean":"tsex clean","compile":"tsex compile","benchmark":"tsex benchmark","test:watch":"tsex test --watch","compile:watch":"tsex compile --watch","prepublishOnly":"tsex prepare","benchmark:watch":"tsex benchmark --watch","benchmark:prepare":"cd tasks && git clone https://github.com/babel/babel.git"},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"repository":{"url":"git+https://github.com/fabiospampinato/fast-ignore.git","type":"git"},"_npmVersion":"10.2.3","description":"A fast parser and processor for .gitignore files.","directories":{},"_nodeVersion":"18.19.0","dependencies":{"grammex":"^3.1.2","string-escape-regex":"^1.0.0"},"_hasShrinkwrap":false,"devDependencies":{"fava":"^0.3.1","tsex":"^3.0.1","benchloop":"^2.1.1","typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/fast-ignore_1.1.3_1711670751562_0.16534870172636196","host":"s3://npm-registry-packages"}},"2.0.0":{"name":"fast-ignore","repository":{"type":"git","url":"git+https://github.com/fabiospampinato/fast-ignore.git"},"description":"A fast parser and processor for .gitignore files.","license":"MIT","version":"2.0.0","type":"module","main":"dist/index.js","exports":"./dist/index.js","types":"./dist/index.d.ts","scripts":{"benchmark":"tsex benchmark","benchmark:watch":"tsex benchmark --watch","benchmark:prepare":"cd tasks && git clone https://github.com/babel/babel.git","clean":"tsex clean","compile":"tsex compile","compile:watch":"tsex compile --watch","test":"node test/index.js","test:watch":"tsex test --watch","prepublishOnly":"npm run clean && npm run compile && npm run test"},"keywords":["fast","gitignore","dotignore","ignore"],"dependencies":{"grammex":"^3.1.12","string-escape-regex":"^1.0.1"},"devDependencies":{"benchloop":"^2.1.1","fava":"^0.3.5","tsex":"^4.0.2","typescript":"^5.9.3"},"gitHead":"9adbb13850501232c728fa2fd486da239c2ae596","_id":"fast-ignore@2.0.0","bugs":{"url":"https://github.com/fabiospampinato/fast-ignore/issues"},"homepage":"https://github.com/fabiospampinato/fast-ignore#readme","_nodeVersion":"24.11.1","_npmVersion":"11.6.2","dist":{"integrity":"sha512-41OOPBgTDyVjF2oytGXvmqm56a38znzWLTQhvD3gp3FPCs37+j7qYjWDnL2WEA0P/Z80W53MKAXNJxc0JT8Tpw==","shasum":"9b7386c69cef056c93fc8db02bb678cee91d2e4a","tarball":"https://registry.npmjs.org/fast-ignore/-/fast-ignore-2.0.0.tgz","fileCount":23,"unpackedSize":17052,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCCbAx8KZwB7rqiG8V8Wo/Ru/PO93Uvp6+d/aIFBuvbxAIgZI5ihIve87A/C9xFuG8YXS1KycugtVFzOtqAuDzsKVk="}]},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"directories":{},"maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/fast-ignore_2.0.0_1771183936818_0.7971073839765488"},"_hasShrinkwrap":false}},"time":{"created":"2023-12-09T01:12:03.123Z","modified":"2026-02-15T19:32:17.070Z","1.0.0":"2023-12-09T01:12:03.320Z","1.1.0":"2023-12-09T16:01:24.250Z","1.1.1":"2023-12-09T16:45:23.375Z","1.1.2":"2024-03-28T20:46:08.778Z","1.1.3":"2024-03-29T00:05:51.717Z","2.0.0":"2026-02-15T19:32:16.948Z"},"bugs":{"url":"https://github.com/fabiospampinato/fast-ignore/issues"},"homepage":"https://github.com/fabiospampinato/fast-ignore#readme","keywords":["fast","gitignore","dotignore","ignore"],"repository":{"type":"git","url":"git+https://github.com/fabiospampinato/fast-ignore.git"},"description":"A fast parser and processor for .gitignore files.","maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"readme":"# Fast Ignore\n\nA fast parser and processor for `.gitignore` files.\n\n## Install\n\n```sh\nnpm install fast-ignore\n```\n\n## Usage\n\n```ts\nimport fastIgnore from 'fast-ignore';\n\n// Let's create the content of a .gitignore file\n\nconst gitignore = `\n# Some always-ignore files\n*~\n*.err\n*.log\n._*\n.cache\n.fseventsd\n.DocumentRevisions*\n.DS_Store\n.TemporaryItems\n.Trashes\nThumbs.db\n\n# Some project-specific ignores\ndist\nnode_modules\n\n# Some directory-only ignores\ndir/\n`;\n\n// Let's create our ignore function\n\nconst ignore = fastIgnore ( gitignore );\n\n// Now we can check if a relative path should be ignored\n\nignore ( 'foo/bar.js' ); // false\nignore ( 'node_modules/foo/bar.js' ); // true\nignore ( 'dist/foo/bar.js' ); // true\n\n// Directory-only globs are supported _automatically_ when the situation is unambiguous\n// In the following scenario we know for sure that \"dir\" must be a directory, so it's ignored\n\nignore ( 'dir/foo.js' ); // true\n\n// Directory-only globs are supported _manually_ when the situation is ambiguous\n// In the following scenario we can't know for sure if \"dir\" is a file or a directory\n// We are going to assume it's not a directory, but if it is then you need to tell the library via the options object\n\nignore ( 'dir' ); // false\nignore ( 'dir', { isDirectory: true } ); // true\n\n// We can also work with multiple ignore files at once, which is faster than handling them individually\n// This goes roughly as fast as just concatenating the files together, but with the semantics of separate files\n// The difference is that an ignore file that comes later won't be able to un-ignore something that was ignored by a previous one\n// As a result please note that writing `fastIgnore ([ 'dist', '!dist' ])` may work differently than you expected\n\nconst prettierignore = `\n**/test\n**/__test__\n\n# The following globs are effectively useless\n# because they can't un-ignore something that was ignored by any previous ignore files\n!dist\n!node_modules\n`;\n\nconst comboIgnore = fastIgnore ([ gitignore, prettierignore ]);\n\ncomboIgnore ( 'foo/bar.js' ); // false\ncomboIgnore ( 'node_modules/foo/bar.js' ); // true\ncomboIgnore ( 'dist/foo/bar.js' ); // true\ncomboIgnore ( 'test/foo/bar.js' ); // true\n```\n\n## License\n\nMIT © Fabio Spampinato\n","readmeFilename":"readme.md","license":"MIT"}