{"id":14968137,"url":"https://github.com/postcss/postcss-selector-matches","last_synced_at":"2025-04-09T09:09:15.888Z","repository":{"id":31213223,"uuid":"34774253","full_name":"postcss/postcss-selector-matches","owner":"postcss","description":"PostCSS plugin to transform :matches() W3C CSS pseudo class to more compatible CSS (simpler selectors)","archived":false,"fork":false,"pushed_at":"2020-10-03T22:16:42.000Z","size":27,"stargazers_count":44,"open_issues_count":5,"forks_count":10,"subscribers_count":10,"default_branch":"master","last_synced_at":"2024-10-29T14:38:24.962Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/postcss.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-04-29T05:30:52.000Z","updated_at":"2023-01-17T00:22:47.000Z","dependencies_parsed_at":"2022-07-22T04:31:53.401Z","dependency_job_id":null,"html_url":"https://github.com/postcss/postcss-selector-matches","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postcss%2Fpostcss-selector-matches","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postcss%2Fpostcss-selector-matches/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postcss%2Fpostcss-selector-matches/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postcss%2Fpostcss-selector-matches/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/postcss","download_url":"https://codeload.github.com/postcss/postcss-selector-matches/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247657971,"owners_count":20974498,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-09-24T13:39:22.432Z","updated_at":"2025-04-09T09:09:15.857Z","avatar_url":"https://github.com/postcss.png","language":"JavaScript","readme":"# postcss-selector-matches [![CSS Standard Status](https://cssdb.org/badge/matches-pseudo-class.svg)](https://cssdb.org/#matches-pseudo-class) [![Build Status](https://travis-ci.org/postcss/postcss-selector-matches.svg?branch=master)](https://travis-ci.org/postcss/postcss-selector-matches)\n\n\u003e PostCSS plugin to transform `:matches()` W3C CSS pseudo class to more compatible CSS selectors\n\nhttp://dev.w3.org/csswg/selectors-4/#matches\n\n## Installation\n\n```console\n$ npm install postcss-selector-matches\n```\n\n## Usage\n\n```js\nvar postcss = require(\"postcss\")\n\nvar output = postcss()\n  .use(require(\"postcss-selector-matches\"))\n  .process(require(\"fs\").readFileSync(\"input.css\", \"utf8\"))\n  .css\n```\n\nUsing this `input.css`:\n\n```css\np:matches(:first-child, .special) {\n  color: red;\n}\n```\n\nyou will get:\n\n```css\np:first-child, p.special {\n  color: red;\n}\n```\n\n**Note that if you are doing crazy selector like `p:matches(a) {}` you are likely to get crazy results (like `pa {}`)**.\n\n\n## Options\n\n### `lineBreak`\n\n(default: `false`)\n\nAllows you to introduce a line break between generated selectors.\n\n---\n\n## [Changelog](CHANGELOG.md)\n\n## [License](LICENSE)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpostcss%2Fpostcss-selector-matches","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpostcss%2Fpostcss-selector-matches","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpostcss%2Fpostcss-selector-matches/lists"}