{"id":16390183,"url":"https://github.com/slamdunk/stylelint-no-browser-hacks","last_synced_at":"2025-09-14T05:12:39.305Z","repository":{"id":60774776,"uuid":"82160883","full_name":"Slamdunk/stylelint-no-browser-hacks","owner":"Slamdunk","description":"Stylelint plugin for stylehacks linting","archived":false,"fork":false,"pushed_at":"2024-02-19T14:31:32.000Z","size":124,"stargazers_count":13,"open_issues_count":1,"forks_count":5,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-10-12T04:35:06.828Z","etag":null,"topics":["no-browser-hacks","stylehacks","stylelint","stylelint-plugin"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":false,"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/Slamdunk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["Slamdunk"],"custom":"https://paypal.me/filippotessarotto"}},"created_at":"2017-02-16T09:03:21.000Z","updated_at":"2024-02-19T13:34:59.000Z","dependencies_parsed_at":"2024-06-18T16:00:51.923Z","dependency_job_id":"937fc448-2e1f-4bab-a4da-0e2f32d717a4","html_url":"https://github.com/Slamdunk/stylelint-no-browser-hacks","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Slamdunk%2Fstylelint-no-browser-hacks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Slamdunk%2Fstylelint-no-browser-hacks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Slamdunk%2Fstylelint-no-browser-hacks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Slamdunk%2Fstylelint-no-browser-hacks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Slamdunk","download_url":"https://codeload.github.com/Slamdunk/stylelint-no-browser-hacks/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221811384,"owners_count":16884305,"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":["no-browser-hacks","stylehacks","stylelint","stylelint-plugin"],"created_at":"2024-10-11T04:35:10.693Z","updated_at":"2025-09-14T05:12:39.294Z","avatar_url":"https://github.com/Slamdunk.png","language":"JavaScript","funding_links":["https://github.com/sponsors/Slamdunk","https://paypal.me/filippotessarotto"],"categories":[],"sub_categories":[],"readme":"# stylelint-no-browser-hacks\n\n[![Node.js CI](https://github.com/Slamdunk/stylelint-no-browser-hacks/actions/workflows/test.yml/badge.svg)](https://github.com/Slamdunk/stylelint-no-browser-hacks/actions/workflows/test.yml)\n[![Latest version][npm-v-img]][npm]\n[![Downloads][npm-d-img]][npm]\n\nA [stylelint] plugin that disallow browser hacks that are irrelevant to the\nbrowsers you are targeting, using [stylehacks].\n\nOriginal rule: [stylelint/no-browser-hacks][original-rule].\n\nDisallow browser hacks that are irrelevant to the browsers you are targeting.\n\n```css\nh1 { _color: white; }\n/**  ↑\n * Hacks like this */\n```\n\nIf you are uncertain what \"browser hacks\" are, [\"An Introduction to\nBrowser-Specific Hacks\"][sitepoint-browser-specific-css-hacks]\nexplains it well.\n\nThis rule uses [stylehacks] to detect the hacks. Then, in the spirit of\nstylelint, it tells you that you've done something wrong. If instead you would\nlike to automatically remove browser hacks, use [stylehacks] directly.\n\n[stylehacks] is only compatible with standard CSS syntax, and does not support\nnested properties nor custom property sets.\n\nBugs and feature requests should be reported on the\n[stylehacks issue tracker][stylehacks-issues].\n\n## Installation\n\n```\nnpm install stylelint-no-browser-hacks\n```\n\n## Usage\n\nAdd `stylelint-no-browser-hacks` to your stylelint config plugins array, then\nadd rules you need to the rules list.\nNote that the rule is namespaced with `plugin/`.\n\nLike so:\n\n```json\n// .stylelintrc\n{\n\t\"plugins\": [\n\t\t\"stylelint-no-browser-hacks\"\n\t],\n\t\"rules\": {\n\t\t// ...\n\t\t\"plugin/no-browser-hacks\": [true],\n\t\t// ...\n\t}\n}\n```\n\n## Options\n\n### `true`\n\nDefaults to the browserslist default, which targets modern browsers.\n\nThe following patterns are considered warnings:\n\n```css\na { color/*\\**/: pink\\9; }\n```\n\nAs this hack targets IE7-8.\n\n[npm]: https://www.npmjs.com/package/stylelint-no-browser-hacks\n[npm-v-img]: https://img.shields.io/npm/v/stylelint-no-browser-hacks.svg\n[npm-d-img]: https://img.shields.io/npm/dt/stylelint-no-browser-hacks.svg\n[stylelint]: https://stylelint.io/\n[stylehacks]: https://github.com/ben-eb/stylehacks\n[stylehacks-issues]: https://github.com/ben-eb/stylehacks/issues\n[original-rule]: https://github.com/stylelint/stylelint/tree/7.9.0/lib/rules/no-browser-hacks\n[sitepoint-browser-specific-css-hacks]: https://www.sitepoint.com/browser-specific-css-hacks/\n[browserslist]: https://github.com/ai/browserslist\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslamdunk%2Fstylelint-no-browser-hacks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fslamdunk%2Fstylelint-no-browser-hacks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslamdunk%2Fstylelint-no-browser-hacks/lists"}