{"_id":"@aleph/stylelint-config","_rev":"5-f9fd617683bdbc731637b239e9429031","name":"@aleph/stylelint-config","dist-tags":{"latest":"2.1.1"},"versions":{"1.0.0":{"name":"@aleph/stylelint-config","version":"1.0.0","keywords":["stylelint","stylelint-config","css","scss","sass","styled-components","aleph","code-style","linting"],"author":{"name":"Aleph Inc."},"license":"MIT","_id":"@aleph/stylelint-config@1.0.0","maintainers":[{"name":"alephsf","email":"ping@alephsf.com"},{"name":"oppodeldoc","email":"matt@alephsf.com"},{"name":"tusinga","email":"amanda@alephsf.com"}],"homepage":"https://docs.aleph.inc/docs/resources/4devs/standards/code-style-standards","bugs":{"url":"https://github.com/aleph-inc/aleph-docs/issues"},"dist":{"shasum":"cb024a14a77012e41eff67c1707d93c12e46dc47","tarball":"https://registry.npmjs.org/@aleph/stylelint-config/-/stylelint-config-1.0.0.tgz","fileCount":4,"integrity":"sha512-F/YMIq1gu9UC1PU76QE7VMDARrs84UkNEx/hABJsUEndW5ojMa0S4IEVAdO8FMSeHfw9TFrXFCDiCmYI+mdJsQ==","signatures":[{"sig":"MEUCIFYHVv9huV6vmuygpLuXpVGpmqsuklobxxzPKV7ggys5AiEA+rU7mRZ6M5Tk/QwMpwebBDAwKng1wmrewbIgq31o1bY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":18442},"main":"index.js","type":"commonjs","engines":{"node":">=16.0.0"},"exports":{".":{"import":"./index.js","require":"./index.js"}},"gitHead":"b81669ba5766f59af45bee73627332a834d7bebb","_npmUser":{"name":"alephsf","email":"ping@alephsf.com"},"repository":{"url":"git+https://github.com/aleph-inc/aleph-docs.git","type":"git","directory":"packages/stylelint-config-aleph"},"_npmVersion":"10.8.0","description":"Aleph's StyleLint configuration for CSS, SCSS, and styled-components","directories":{},"_nodeVersion":"20.13.1","dependencies":{"stylelint-scss":"^6.0.0","stylelint-order":"^6.0.0","stylelint-config-standard":"^36.0.0","stylelint-config-standard-scss":"^13.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"peerDependencies":{"stylelint":">=16.0.0"},"_npmOperationalInternal":{"tmp":"tmp/stylelint-config_1.0.0_1755055798147_0.43621515455806414","host":"s3://npm-registry-packages-npm-production"}},"1.1.0":{"name":"@aleph/stylelint-config","version":"1.1.0","keywords":["stylelint","stylelint-config","css","scss","sass","styled-components","aleph","code-style","linting"],"author":{"name":"Aleph Inc."},"license":"MIT","_id":"@aleph/stylelint-config@1.1.0","maintainers":[{"name":"alephsf","email":"ping@alephsf.com"},{"name":"oppodeldoc","email":"matt@alephsf.com"},{"name":"tusinga","email":"amanda@alephsf.com"}],"homepage":"https://docs.aleph.inc/docs/resources/4devs/standards/code-style-standards","bugs":{"url":"https://github.com/aleph-inc/aleph-docs/issues"},"dist":{"shasum":"a6aec3f116665187d1ff9a76ec31d3d9e8342e49","tarball":"https://registry.npmjs.org/@aleph/stylelint-config/-/stylelint-config-1.1.0.tgz","fileCount":4,"integrity":"sha512-TkTbxkBdZZYWepCk+9I49owE5SvUXGWeaCVFADPxeNQbx2BSFTCYbm860DsgHLyAd6UXwpfZXKiR6WTfsYADDQ==","signatures":[{"sig":"MEYCIQC98D99JhB7bzZ9U3eVvPo5pohzBAuoVOY56VMDL68G5wIhANfZV9ENqhqig8ri8kG77aa/YCmDQXSr8sKqfwyz+fuF","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":20881},"main":"index.js","type":"commonjs","engines":{"node":">=16.0.0"},"exports":{".":{"import":"./index.js","require":"./index.js"}},"gitHead":"8d313d0046bfb23fc4ff09f16fce2f955f222b64","_npmUser":{"name":"alephsf","email":"ping@alephsf.com"},"repository":{"url":"git+https://github.com/aleph-inc/aleph-docs.git","type":"git","directory":"packages/stylelint-config-aleph"},"_npmVersion":"10.8.0","description":"Aleph's StyleLint configuration for CSS, SCSS, and styled-components","directories":{},"_nodeVersion":"20.13.1","dependencies":{"stylelint-scss":"^6.0.0","stylelint-order":"^6.0.0","stylelint-config-standard":"^36.0.0","stylelint-config-standard-scss":"^13.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"peerDependencies":{"stylelint":">=16.0.0"},"_npmOperationalInternal":{"tmp":"tmp/stylelint-config_1.1.0_1755056278616_0.10802873631064269","host":"s3://npm-registry-packages-npm-production"}},"2.0.0":{"name":"@aleph/stylelint-config","version":"2.0.0","keywords":["stylelint","stylelint-config","css","scss","sass","styled-components","aleph","code-style","linting"],"author":{"name":"Aleph Inc."},"license":"MIT","_id":"@aleph/stylelint-config@2.0.0","maintainers":[{"name":"alephsf","email":"ping@alephsf.com"},{"name":"oppodeldoc","email":"matt@alephsf.com"},{"name":"tusinga","email":"amanda@alephsf.com"}],"homepage":"https://docs.aleph.inc/docs/resources/4devs/standards/code-style-standards","bugs":{"url":"https://github.com/aleph-inc/aleph-docs/issues"},"dist":{"shasum":"62a3f02f6c865cc383c48a43ffdd74baa3ae398a","tarball":"https://registry.npmjs.org/@aleph/stylelint-config/-/stylelint-config-2.0.0.tgz","fileCount":4,"integrity":"sha512-hNLsR9/JWlP46ooc2GglrY7323fUJjE4CqjKj21r80m6GbiNLT4q/dfZ84cN8zhaOy9oy6933SGQp47W5hrDSw==","signatures":[{"sig":"MEUCIEnjeOYEZsqEELTb3+kYxKhmvewYKR4ET1l7vDN5mfDfAiEArHiq3WG5U2ZZCfSj4UtPhbnkfOJ6NKB5hguwfQYcrzI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":18804},"main":"index.js","type":"commonjs","engines":{"node":">=16.0.0"},"exports":{".":{"import":"./index.js","require":"./index.js"}},"gitHead":"63f41d4fee1108fa5d25c0cb37e6d682a35a09ba","_npmUser":{"name":"alephsf","email":"ping@alephsf.com"},"repository":{"url":"git+https://github.com/aleph-inc/aleph-docs.git","type":"git","directory":"packages/stylelint-config-aleph"},"_npmVersion":"10.8.0","description":"Aleph's StyleLint configuration for CSS, SCSS, and styled-components","directories":{},"_nodeVersion":"20.13.1","dependencies":{"stylelint-scss":"^6.0.0","stylelint-order":"^7.0.0","stylelint-config-standard":"^39.0.0","stylelint-config-standard-scss":"^15.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"peerDependencies":{"stylelint":">=16.0.0"},"_npmOperationalInternal":{"tmp":"tmp/stylelint-config_2.0.0_1755896051310_0.2069250329342578","host":"s3://npm-registry-packages-npm-production"}},"2.1.0":{"name":"@aleph/stylelint-config","version":"2.1.0","keywords":["stylelint","stylelint-config","css","scss","sass","styled-components","aleph","code-style","linting"],"author":{"name":"Aleph Inc."},"license":"MIT","_id":"@aleph/stylelint-config@2.1.0","maintainers":[{"name":"alephsf","email":"ping@alephsf.com"},{"name":"oppodeldoc","email":"matt@alephsf.com"},{"name":"tusinga","email":"amanda@alephsf.com"}],"homepage":"https://docs.aleph.inc/docs/resources/4devs/standards/code-style-standards","bugs":{"url":"https://github.com/aleph-inc/aleph-docs/issues"},"dist":{"shasum":"b1d3550175c08aebbd1c7b39d57d7b7e12fbc8df","tarball":"https://registry.npmjs.org/@aleph/stylelint-config/-/stylelint-config-2.1.0.tgz","fileCount":4,"integrity":"sha512-dOrR9IIK7ASo1i2dwUmg+/cJgpmeM6a3Gnf9B1J6wiYTtLkbFYBFV5BBKg0pZfGGl/jW9nt62qD6VGO51dkKPA==","signatures":[{"sig":"MEQCIFvNV2/cOGYClh5a55yhTYvU15aHGNINdUdZmM77WNnVAiADaHiHviJkQ7oqPhZDY9zAYOSo+xRe0MuOA+lzEEH3XA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":18838},"main":"index.js","type":"commonjs","engines":{"node":">=22.0.0"},"exports":{".":{"import":"./index.js","require":"./index.js"}},"gitHead":"49be4720cdec8784f26bdb0859b9eba6b8f7968e","_npmUser":{"name":"alephsf","email":"ping@alephsf.com"},"repository":{"url":"git+https://github.com/aleph-inc/aleph-docs.git","type":"git","directory":"packages/stylelint-config-aleph"},"_npmVersion":"10.8.0","description":"Aleph's StyleLint configuration for CSS, SCSS, and styled-components","directories":{},"_nodeVersion":"20.13.1","dependencies":{"stylelint-scss":"^6.0.0","stylelint-order":"^7.0.0","stylelint-config-standard":"^39.0.0","stylelint-config-standard-scss":"^15.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"peerDependencies":{"stylelint":">=16.0.0"},"_npmOperationalInternal":{"tmp":"tmp/stylelint-config_2.1.0_1756235619873_0.7153847803721687","host":"s3://npm-registry-packages-npm-production"}},"2.1.1":{"name":"@aleph/stylelint-config","version":"2.1.1","description":"Aleph's StyleLint configuration for CSS, SCSS, and styled-components","main":"index.js","type":"commonjs","exports":{".":{"require":"./index.js","import":"./index.js"}},"keywords":["stylelint","stylelint-config","css","scss","sass","styled-components","aleph","code-style","linting"],"author":{"name":"Aleph Inc."},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/aleph-inc/aleph-docs.git","directory":"packages/stylelint-config-aleph"},"bugs":{"url":"https://github.com/aleph-inc/aleph-docs/issues"},"homepage":"https://docs.aleph.inc/docs/resources/4devs/standards/code-style-standards","publishConfig":{"access":"public"},"dependencies":{"stylelint-config-standard":"^39.0.0","stylelint-config-standard-scss":"^15.0.0","stylelint-order":"^7.0.0","stylelint-scss":"^6.0.0"},"peerDependencies":{"stylelint":">=16.0.0"},"engines":{"node":">=22.0.0"},"_id":"@aleph/stylelint-config@2.1.1","gitHead":"1b08b34169103bc13354b96719b2a5f0ff490326","_nodeVersion":"20.13.1","_npmVersion":"10.8.0","dist":{"integrity":"sha512-nQtdTMVAT1sKbeSNzOZwdjEjxWL57ZMDifCbwLBENXIyCzQf/S11lVrIPsK7OQ5BaQTezMK2dtrbKBkkUDIvPA==","shasum":"c1363dda5f80d1778cfc9dc31cb5f468590cfad9","tarball":"https://registry.npmjs.org/@aleph/stylelint-config/-/stylelint-config-2.1.1.tgz","fileCount":4,"unpackedSize":18944,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIE6tJ46IB2QkMiQMh+rf6KUpgCV4qmnMS4mjFYbhMdmlAiB7YNHo3iPhLzj55FibqMkVCg0DWFV3c3PxTOsIMAPZ8A=="}]},"_npmUser":{"name":"alephsf","email":"ping@alephsf.com"},"directories":{},"maintainers":[{"name":"alephsf","email":"ping@alephsf.com"},{"name":"oppodeldoc","email":"matt@alephsf.com"},{"name":"tusinga","email":"amanda@alephsf.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/stylelint-config_2.1.1_1756236079439_0.17840669974087375"},"_hasShrinkwrap":false}},"time":{"created":"2025-08-13T03:29:58.072Z","modified":"2025-08-26T19:21:19.882Z","1.0.0":"2025-08-13T03:29:58.330Z","1.1.0":"2025-08-13T03:37:58.865Z","2.0.0":"2025-08-22T20:54:11.531Z","2.1.0":"2025-08-26T19:13:40.101Z","2.1.1":"2025-08-26T19:21:19.647Z"},"bugs":{"url":"https://github.com/aleph-inc/aleph-docs/issues"},"author":{"name":"Aleph Inc."},"license":"MIT","homepage":"https://docs.aleph.inc/docs/resources/4devs/standards/code-style-standards","keywords":["stylelint","stylelint-config","css","scss","sass","styled-components","aleph","code-style","linting"],"repository":{"type":"git","url":"git+https://github.com/aleph-inc/aleph-docs.git","directory":"packages/stylelint-config-aleph"},"description":"Aleph's StyleLint configuration for CSS, SCSS, and styled-components","maintainers":[{"name":"alephsf","email":"ping@alephsf.com"},{"name":"oppodeldoc","email":"matt@alephsf.com"},{"name":"tusinga","email":"amanda@alephsf.com"}],"readme":"# @aleph/stylelint-config\n\nAleph's StyleLint configuration for CSS, SCSS, and CSS modules.\n\n## Installation\n\n```bash\nnpm install @aleph/stylelint-config --save-dev\n```\n\n## Usage\n\n### Basic Setup\n\nCreate or update your `stylelint.config.js`:\n\n```javascript\nmodule.exports = {\n  extends: ['@aleph/stylelint-config']\n};\n```\n\nOr using the `stylelint.config.json` format:\n\n```json\n{\n  \"extends\": [\"@aleph/stylelint-config\"]\n}\n```\n\n### Package.json Script\n\nAdd to your `package.json`:\n\n```json\n{\n  \"scripts\": {\n    \"lint:css\": \"stylelint '**/*.{css,scss}'\",\n    \"lint:css:fix\": \"stylelint '**/*.{css,scss}' --fix\"\n  }\n}\n```\n\n## What's Included\n\nThis configuration extends:\n\n- **stylelint-config-standard**: The standard shareable config for StyleLint\n- **stylelint-config-standard-scss**: Standard config for SCSS\n- **stylelint-order**: Property ordering rules\n- **stylelint-scss**: SCSS-specific linting rules\n\n## Philosophy\n\nThis config follows a **minimal override** philosophy - we extend proven standard configs and only add rules where Aleph has specific needs. Most formatting and basic rules come from the standard configs.\n\n## Aleph-Specific Rules\n\n### 🚫 **Disabled Rules (For Flexibility)**\n- **CSS-in-JS Compatibility**: Allows mixed case for better styled-components integration\n- **Flexible Spacing**: Disabled strict empty line requirements for developer convenience\n- **Modern CSS**: Disabled some newer CSS validation rules that can be overly restrictive\n\n### 📏 **Aleph Constraints**\n- **No `!important` declarations**: Stricter than default - forces proper CSS architecture\n- **Selector Limits**: Max 4 compound selectors, no ID selectors, specificity caps\n- **CSS-in-JS Support**: Allows `global` and `local` pseudo-classes\n\n### 📐 **Property Ordering**\nLogical property order enforced:\n- Custom properties first\n- Display & layout → Grid/Flexbox → Dimensions → Spacing → Borders → Background → Typography → Visual effects\n\n### 🔧 **SCSS Flexibility**\n- Allows flexible naming patterns (overrides standard kebab-case requirements)\n- Permits vendor prefixes when needed (for legacy browser support)\n\n## File Support\n\nThis configuration works with:\n\n- **CSS** files (`.css`)\n- **SCSS** files (`.scss`)\n- **Sass** files (`.sass`)\n- **Styled-components** (in JS/TS files)\n- **CSS Modules**\n- **PostCSS** files\n\n## Customization\n\n### Project-Specific Rules\n\nIf your project needs specific rules, extend our base config:\n\n```javascript\n// stylelint.config.js\nmodule.exports = {\n  extends: ['@aleph/stylelint-config'],\n  rules: {\n    // Project-specific overrides\n    'max-line-length': 120, // Longer lines for this project\n    'selector-max-id': 1, // Allow one ID selector\n  },\n  overrides: [\n    {\n      files: ['**/*.scss'],\n      rules: {\n        // SCSS-specific rules\n        'scss/dollar-variable-pattern': null, // Disable variable naming pattern\n      },\n    },\n  ],\n};\n```\n\n### When to Override\n\nOnly override rules when you have a specific need:\n- **Legacy codebases** that can't be easily updated\n- **Third-party CSS** that doesn't follow conventions\n- **Generated styles** from tools\n- **Specific design system requirements**\n\n## IDE Integration\n\n### VS Code Setup\n\nInstall the StyleLint extension and add to `.vscode/settings.json`:\n\n```json\n{\n  \"stylelint.enable\": true,\n  \"editor.codeActionsOnSave\": {\n    \"source.fixAll.stylelint\": true\n  },\n  \"css.validate\": false,\n  \"scss.validate\": false\n}\n```\n\n## CI/CD Integration\n\nAdd linting to your CI pipeline:\n\n```yaml\n# Example GitHub Actions\n- name: Lint CSS\n  run: |\n    npm ci\n    npm run lint:css\n```\n\n## Common Patterns\n\n### SCSS Variables\n\n```scss\n// ✅ Good: Standard kebab-case (enforced by stylelint-config-standard-scss)\n$primary-color: #3498db;\n$font-size-large: 1.25rem;\n$border-radius-small: 0.25rem;\n\n// ⚠️ Allowed: Flexible naming (Aleph override allows other patterns)\n$primaryColor: #3498db;   // camelCase allowed\n$font_size_large: 1.25rem;  // snake_case allowed\n$PRIMARY_COLOR: #3498db;  // UPPER_CASE allowed\n```\n\n### Property Ordering\n\n```scss\n// ✅ Good: Logical property order\n.component {\n  // Custom properties first\n  --local-color: red;\n\n  // Box model\n  display: flex;\n  \n  // Positioning\n  position: relative;\n  top: 0;\n  \n  // Flexbox\n  flex-direction: column;\n  align-items: center;\n  \n  // Dimensions\n  width: 100%;\n  height: auto;\n  \n  // Spacing\n  margin: 1rem;\n  padding: 0.5rem;\n  \n  // Borders\n  border: 1px solid #ccc;\n  border-radius: 0.25rem;\n  \n  // Background\n  background-color: white;\n  \n  // Typography\n  color: #333;\n  font-size: 1rem;\n  \n  // Other\n  opacity: 1;\n  cursor: pointer;\n}\n```\n\n### Selector Structure\n\n```scss\n// ✅ Good: Simple, specific selectors\n.component {\n  &__element {\n    // Element styles\n  }\n  \n  &--modifier {\n    // Modifier styles\n  }\n  \n  &:hover {\n    // Pseudo-class styles\n  }\n}\n\n// ❌ Avoid: Overly complex selectors\n.page .sidebar .widget .component .element.active {\n  // Too specific and hard to maintain\n}\n```\n\n## Troubleshooting\n\n### Common Issues\n\n| Error | Cause | Solution |\n|-------|--------|----------|\n| `Unexpected unknown at-rule` | Using SCSS syntax in CSS file | Use `.scss` extension or configure parser |\n| `Expected single space before \"{\"` | Missing space before opening brace | Add space: `.class {` |\n| `Unexpected vendor-prefix` | Using vendor prefixes | Remove prefixes, use autoprefixer |\n| `Expected newline after \",\"` | Selector list formatting | Put each selector on new line |\n\n### Performance\n\nFor large projects, consider:\n- Using `.stylelintignore` to exclude build directories\n- Running StyleLint only on changed files in CI\n- Using `--cache` flag for faster subsequent runs\n\n## Requirements\n\n- **Node.js** 22+\n- **StyleLint** 16+\n\n## Documentation\n\nFor detailed information about our code style standards and the rationale behind these rules, visit our documentation:\n\n👉 **[Aleph Code Style Standards](https://docs.aleph.inc/docs/resources/4devs/standards/code-style-standards)**\n\n## License\n\nMIT © Aleph Inc.","readmeFilename":"README.md"}