scss-best-practices▌
mindrally/skills · updated Apr 8, 2026
MDX-style export adds YAML metadata + attribution linking explainx.ai and this canonical listing URL.
SCSS architecture guidelines covering file organization, variables, mixins, and maintainable stylesheet patterns.
- ›Implements the 7-1 pattern for scalable folder structure: abstracts, base, components, layout, pages, themes, and vendors with a clear import order
- ›Provides semantic variable naming conventions for colors, typography, spacing, breakpoints, z-index, transitions, and shadows using maps for grouped values
- ›Includes reusable mixins for responsive breakpoints, flexbox utilities
SCSS Best Practices
You are an expert in SCSS (Sassy CSS), CSS architecture, and maintainable stylesheet development.
Key Principles
- Write modular, reusable SCSS that scales with project complexity
- Follow the DRY (Don't Repeat Yourself) principle using variables, mixins, and functions
- Maintain clear separation between structure, skin, and state styles
- Prioritize readability and maintainability over clever abstractions
File Organization
Architecture Pattern (7-1 Pattern)
scss/
├── abstracts/
│ ├── _variables.scss # Global variables
│ ├── _functions.scss # SCSS functions
│ ├── _mixins.scss # Reusable mixins
│ └── _placeholders.scss # Extendable placeholders
├── base/
│ ├── _reset.scss # CSS reset/normalize
│ ├── _typography.scss # Typography rules
│ └── _base.scss # Base element styles
├── components/
│ ├── _buttons.scss # Button components
│ ├── _cards.scss # Card components
│ └── _forms.scss # Form components
├── layout/
│ ├── _header.scss # Header layout
│ ├── _footer.scss # Footer layout
│ ├── _grid.scss # Grid system
│ └── _navigation.scss # Navigation layout
├── pages/
│ ├── _home.scss # Home page specific
│ └── _contact.scss # Contact page specific
├── themes/
│ └── _default.scss # Default theme
├── vendors/
│ └── _bootstrap.scss # Third-party overrides
└── main.scss # Main manifest file
Import Order
// main.scss
@use 'abstracts/variables';
@use 'abstracts/functions';
@use 'abstracts/mixins';
@use 'abstracts/placeholders';
@use 'vendors/normalize';
@use 'base/reset';
@use 'base/typography';
@use 'base/base';
@use 'layout/grid';
@use 'layout/header';
@use 'layout/navigation';
@use 'layout/footer';
@use 'components/buttons';
@use 'components/cards';
@use 'components/forms';
@use 'pages/home';
@use 'themes/default';
Variables
Naming Convention
// Use semantic, descriptive names
// Format: $category-property-variant
// Colors
$color-primary: #3498db;
$color-primary-light: lighten($color-primary, 15%);
$color-primary-dark: darken($color-primary, 15%);
$color-secondary: #2ecc71;
$color-text: #333333;
$color-text-muted: #666666;
$color-background: #ffffff;
$color-border: #e0e0e0;
$color-error: #e74c3c;
$color-success: #27ae60;
$color-warning: #f39c12;
// Typography
$font-family-base: 'Helvetica Neue', Arial, sans-serif;
$font-family-heading: 'Georgia', serif;
$font-size-base: 1rem;
$font-size-small: 0.875rem;
$font-size-large: 1.25rem;
$font-weight-normal: 400;
$font-weight-bold: 700;
$line-height-base: 1.5;
// Spacing (use consistent scale)
$spacing-unit: 8px;
$spacing-xs: $spacing-unit * 0.5; // 4px
$spacing-sm: $spacing-unit; // 8px
$spacing-md: $spacing-unit * 2; // 16px
$spacing-lg: $spacing-unit * 3; // 24px
$spacing-xl: $spacing-unit * 4; // 32px
$spacing-xxl: $spacing-unit * 6; // 48px
// Breakpoints
$breakpoint-sm: 576px;
$breakpoint-md: 768px;
$breakpoint-lg: 992px;
$breakpoint-xl: 1200px;
$breakpoint-xxl: 1400px;
// Z-index scale
$z-index-dropdown: 1000;
$z-index-sticky: 1020;
$z-index-fixed: 1030;
$z-index-modal-backdrop: 1040;
$z-index-modal: 1050;
$z-index-popover: 1060;
$z-index-tooltip: 1070;
// Transitions
$transition-base: 0.3s ease;
$transition-fast: 0.15s ease;
$transition-slow: 0.5s ease;
// Border radius
$border-radius-sm: 2px;
$border-radius-md: 4px;
$border-radius-lg: 8px;
$border-radius-pill: 50px;
$border-radius-circle: 50%;
// Shadows
$shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
$shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
$shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
$shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
Maps for Related Values
// Use maps for grouped values
$colors: (
'primary': #3498db,
'secondary': #2ecc71,
'danger': #e74c3c,
'warning': #f39c12,
'info': #17a2b8,
'success': #27ae60
);
$breakpoints: (
'sm': 576px,
'md': 768px,
'lg': 992px,
'xl': 1200px,
'xxl': 1400px
);
// Access with map-get
.element {
color: map-get($colors, 'primary');
}
Mixins
Responsive Breakpoints
@mixin respond-to($breakpoint) {
@if map-has-key($breakpoints, $breakpoint) {
@media (min-width: map-get($breakpoints, $breakpointhow to use scss-best-practicesHow to use scss-best-practices on Cursor
AI-first code editor with Composer
1Prerequisites
Before installing skills in Cursor, ensure your development environment meets these requirements:
- ›Cursor installed and configured on your development machine
- ›Node.js version 16.0+ with npm package manager (verify with
node --version) - ›Active project directory or workspace where you want to add scss-best-practices
2Execute installation command
Execute the skills CLI command in your project's root directory to begin installation:
$npx skills add https://github.com/mindrally/skills --skill scss-best-practicesThe skills CLI fetches scss-best-practices from GitHub repository mindrally/skills and configures it for Cursor.
3Select Cursor when prompted
The CLI will show a list of available agents. Use arrow keys to navigate and space to select Cursor:
◆ Which agents do you want to install to?││ ── Universal (.agents/skills) ── always included ────│ • Amp│ • Antigravity│ • Cline│ • Codex│ ●Cursor(selected)│ • Cursor│ • Windsurf4Verify installation
Confirm successful installation by checking the skill directory location:
.cursor/skills/scss-best-practicesReload or restart Cursor to activate scss-best-practices. Access the skill through slash commands (e.g., /scss-best-practices) or your agent's skill management interface.
⚠Security & Verification Notice
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your development environment. Always verify the publisher's identity, review recent commits, and test in isolated environments before production deployment.
Additional Resources
List & Monetize Your Skill
Submit your Claude Code skill and start earning
GET_STARTED →Use Cases▌
Task Automation & Efficiency
Automate repetitive workflows and reduce manual effort
Example
Generate reports, summarize documents, draft communications
✓Save 3-5 hours per week on routine tasks
Knowledge Enhancement
Learn new skills, understand complex topics, get expert guidance
Example
Explain concepts, provide examples, suggest learning resources
✓Accelerate learning and skill development by 2x
Quality Improvement
Enhance output quality through reviews, suggestions, and refinements
Example
Review drafts, suggest improvements, catch errors
✓Improve work quality by 30-40% with less effort
Implementation Guide▌
Prerequisites
- ›Claude Desktop or compatible AI client with skill support
- ›Clear understanding of task or problem to solve
- ›Willingness to iterate and refine outputs
Time Estimate
15-45 minutes depending on use case complexity
Installation Steps
- 1.Install skill using provided installation command
- 2.Test with simple use case relevant to your work
- 3.Evaluate output quality and relevance
- 4.Iterate on prompts to improve results
- 5.Integrate into regular workflow if valuable
Common Pitfalls
- ⚠Expecting perfect results without iteration
- ⚠Not providing enough context in prompts
- ⚠Using skill for tasks outside its intended scope
- ⚠Accepting outputs without review and validation
Best Practices▌
✓ Do
- +Start with clear, specific prompts
- +Provide relevant context and constraints
- +Review and refine all outputs before using
- +Iterate to improve output quality
- +Document successful prompt patterns
✗ Don't
- −Don't use without understanding skill limitations
- −Don't skip validation of outputs
- −Don't share sensitive information in prompts
- −Don't expect skill to replace human judgment
💡 Pro Tips
- ★Be specific about desired format and style
- ★Ask for multiple options to choose from
- ★Request explanations to understand reasoning
- ★Combine AI efficiency with human expertise
When to Use This▌
✓ Use When
Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.
✗ Avoid When
Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.
Learning Path▌
- 1Familiarize yourself with skill capabilities and limitations
- 2Start with low-risk, non-critical tasks
- 3Progress to more complex and valuable use cases
- 4Build expertise through regular use and experimentation
Discussion
Product Hunt–style comments (not star reviews)- No comments yet — start the thread.
general reviewsRatings
4.5★★★★★71 reviews- ★★★★★Ganesh Mohane· Dec 28, 2024
Useful defaults in scss-best-practices — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
- ★★★★★Charlotte Khan· Dec 28, 2024
scss-best-practices reduced setup friction for our internal harness; good balance of opinion and flexibility.
- ★★★★★Aarav Menon· Dec 24, 2024
scss-best-practices is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
- ★★★★★Aarav Sanchez· Dec 12, 2024
Keeps context tight: scss-best-practices is the kind of skill you can hand to a new teammate without a long onboarding doc.
- ★★★★★Maya Li· Dec 12, 2024
Useful defaults in scss-best-practices — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
- ★★★★★Aarav Jain· Dec 8, 2024
scss-best-practices is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
- ★★★★★Nia Khanna· Nov 27, 2024
We added scss-best-practices from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.
- ★★★★★Aanya Martin· Nov 27, 2024
scss-best-practices reduced setup friction for our internal harness; good balance of opinion and flexibility.
- ★★★★★Henry Abbas· Nov 23, 2024
scss-best-practices fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.
- ★★★★★Rahul Santra· Nov 19, 2024
scss-best-practices has been reliable in day-to-day use. Documentation quality is above average for community skills.
showing 1-10 of 71
1 / 8