{"_id":"@afzalsayed96/postcss-purgecss","_rev":"1-5084d81870e12877d41e030bdef92244","name":"@afzalsayed96/postcss-purgecss","dist-tags":{"latest":"2.1.0"},"versions":{"2.1.0":{"name":"@afzalsayed96/postcss-purgecss","version":"2.1.0","description":"PostCSS plugin for PurgeCSS","author":{"name":"afzalsayed96"},"homepage":"https://github.com/afzalsayed96/purgecss#readme","license":"MIT","main":"lib/postcss-purgecss.js","module":"lib/postcss-purgecss.esm.js","types":"lib/postcss-purgecss.d.ts","directories":{"lib":"lib"},"repository":{"type":"git","url":"git+https://github.com/afzalsayed96/purgecss.git"},"scripts":{"test":"echo \"Error: run tests from root\" && exit 1"},"bugs":{"url":"https://github.com/afzalsayed96/purgecss/issues"},"dependencies":{"postcss":"7.0.27","@afzalsayed96/purgecss":"^2.1.0"},"devDependencies":{},"_id":"@afzalsayed96/postcss-purgecss@2.1.0","_nodeVersion":"13.11.0","_npmVersion":"6.13.7","dist":{"integrity":"sha512-tUFgXWKJz5EtBrLk9PmxOZyQnjOkFvMG5BUVvbuv0Ue16tbAR51V39w1u31RYZil5RdNb3GM7jz/A6ziIqzhXA==","shasum":"d5f478c46c9a978b172e8552288187f668dce1f5","tarball":"https://registry.npmjs.org/@afzalsayed96/postcss-purgecss/-/postcss-purgecss-2.1.0.tgz","fileCount":6,"unpackedSize":8613,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeiGCGCRA9TVsSAnZWagAA4IEP/iWwHJ7z+l/kV4pr1+vR\nJJKqy/uD5VLLjjYTb5Vi/LIPNWCGUmOwMii8ZhoIjBH0vM6SgA0EFBmePyUV\nrYeN3GHsd0mXflYJeNy9Kkc62hxvRkiuRImR2SFuS+xp0WR+ExRsldEgG+T1\n+1t2ELGRsWYBzS6XBxbOMnZ+z0a1UKakT8CgytEoyP0hHx5cc563ZjJbnXSK\nkmC2VM8cpDWoP7vQvoVgY0ovg5F6zLvnMeOypZxUS5OUWVz8zlM+E+gOrhtt\naFa1PVt4vyFPNFpWpY2BdemwA87lCTtnWjLOkWbHr+Dp28rqqONerg8htVVc\nY6twhU5OnUrbJ5ldnY3bjml041hfBMf7YAtoPdDHmjp5WPSo9PnODP7TyWUi\nhcBhnBIvo7gbMLvJNoCmwKr7tXwMHomVpi7dLKz9NsrQzHdbZ5hxSiYw+mjU\nGQ8y3IKD5O5F70m7y8011MxBrDvC0j06s41zL90dY85oCAlwpCPB1lo5stMn\nr4g7vZ+W1FViIeDXVaMKqrue6JsouF9CWBOPzp0RBctHqWrfcoaLa3neCoxK\njdlrj6OgFplaAdiZ5kFMyJMdB8I2xx/KpOXCU9Ol/+htKPe8lzmKxhLPSATO\noAP9Ml+U6yKaatzAqVfKNsIcqvmZY2qNTSJHeytjhSPnF9D0PrLUMFX89Hmk\n/NqP\r\n=GnN9\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHKl7d9hN6INKdc3zKduYXvLbyt5NdCVVUhufyD+Iq2HAiBzZ4jGl3JK+6H83NzYbKFmHrJjbPtAp/qc38gu1vCAMA=="}]},"maintainers":[{"name":"afzalsayed96","email":"afzalsayed96@gmail.com"}],"_npmUser":{"name":"afzalsayed96","email":"afzalsayed96@gmail.com"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/postcss-purgecss_2.1.0_1585995909769_0.04135236783530383"},"_hasShrinkwrap":false}},"time":{"created":"2020-04-04T10:25:09.527Z","2.1.0":"2020-04-04T10:25:09.903Z","modified":"2022-04-04T11:52:56.911Z"},"maintainers":[{"name":"afzalsayed96","email":"afzalsayed96@gmail.com"}],"description":"PostCSS plugin for PurgeCSS","homepage":"https://github.com/afzalsayed96/purgecss#readme","repository":{"type":"git","url":"git+https://github.com/afzalsayed96/purgecss.git"},"author":{"name":"afzalsayed96"},"bugs":{"url":"https://github.com/afzalsayed96/purgecss/issues"},"license":"MIT","readme":"# PostCSS Purgecss\n![David (path)](https://img.shields.io/david/FullHuman/purgecss?path=packages%2Fpostcss-purgecss&style=for-the-badge)\n![Dependabot](https://img.shields.io/badge/dependabot-enabled-%23024ea4?style=for-the-badge)\n![npm](https://img.shields.io/npm/v/@fullhuman/postcss-purgecss?style=for-the-badge)\n![npm](https://img.shields.io/npm/dw/@fullhuman/postcss-purgecss?style=for-the-badge)\n![GitHub](https://img.shields.io/github/license/FullHuman/purgecss?style=for-the-badge)\n\n[PostCSS] plugin for PurgeCSS.\n\n[PostCSS]: https://github.com/postcss/postcss\n\n## Installation\n\n```\nnpm i -D @fullhuman/postcss-purgecss\n```\n\n## Usage\n\n```js\nconst purgecss = require('@fullhuman/postcss-purgecss')\npostcss([\n  purgecss({\n    content: ['./src/**/*.html']\n  })\n])\n```\n\nSee [PostCSS] docs for examples for your environment.\n\n## Options\n\nAll of the options of purgecss are available to use with the plugins.\nYou will find below the main options available. For the complete list, go to the [purgecss documentation website](https://www.purgecss.com/configuration.html#options).\n\n### `content` (**required** or use `contentFunction` instead)\nType: `Array<string>`\n\nYou can specify content that should be analyzed by Purgecss with an array of filenames or globs. The files can be HTML, Pug, Blade, etc.\n\n### `contentFunction` (as alternative to `content`)\nType: `(sourceInputFile: string) => Array<string>`\n\nThe function receives the current source input file. With this you may provide a specific array of globs for each input. E.g. for \nan angular application only scan the components template counterpart for every component scss file:\n\n```js\npurgecss({\n  contentFunction: (sourceInputFileName: string) => {\n    if (/component\\.scss$/.test(sourceInputFileName))\n      return [sourceInputFileName.replace(/scss$/, 'html')]\n    else\n      return ['./src/**/*.html']\n  },\n})\n```\n\n### `extractors`\nType: `Array<Object>`\n\nPurgecss can be adapted to suit your needs. If you notice a lot of unused CSS is not being removed, you might want to use a custom extractor.\nMore information about extractors [here](https://www.purgecss.com/extractors.html).\n\n### `whitelist`\nType: `Array<string>`\n\nYou can whitelist selectors to stop Purgecss from removing them from your CSS. This can be accomplished with the options whitelist and whitelistPatterns.\n\n### `whitelistPatterns`\nType: `Array<RegExp>`\n\nYou can whitelist selectors based on a regular expression with whitelistPatterns.\n\n### `rejected`\nType: `boolean`\nDefault value: `false`\n\nIf true, purged selectors will be captured and rendered as PostCSS messages.\nUse with a PostCSS reporter plugin like [`postcss-reporter`](https://github.com/postcss/postcss-reporter)\nto print the purged selectors to the console as they are processed.\n\n### `keyframes`\nType: `boolean`\nDefault value: `false`\n\nIf you are using a CSS animation library such as animate.css, you can remove unused keyframes by setting the keyframes option to true.\n\n#### `fontFace`\nType: `boolean`\nDefault value: `false`\n\nIf there are any unused @font-face rules in your css, you can remove them by setting the fontFace option to true.\n\n## Contributing\n\nPlease read [CONTRIBUTING.md](./../../CONTRIBUTING.md) for details on our code of\nconduct, and the process for submitting pull requests to us.\n\n## Versioning\n\npostcss-purgecss use [SemVer](http://semver.org/) for versioning.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](./../../LICENSE) file\nfor details.\n","readmeFilename":"README.md"}