

Also from Kynth Studios


Also from Kynth Studios


Also from Kynth Studios
123456# Rails Styling with TailwindCSS78## Core Philosophy910- Use utility-first CSS for rapid development11- Avoid writing custom CSS when utilities exist12- Keep styling consistent across the application13- Design mobile-first, enhance for desktop14- Let TailwindCSS handle the complexity1516## TailwindCSS Principles1718- Compose styles using utility classes19- Avoid premature abstraction into components20- Use consistent spacing and sizing scales21- Leverage TailwindCSS's design system22- Keep HTML as the source of truth for styling2324## Configuration Strategy2526- Extend default theme rather than replacing it27- Define custom colors sparingly28- Use CSS variables for dynamic theming29- Configure content paths correctly30- Keep configuration minimal3132## Rails Integration3334- Use Tailwind's standalone CLI approach35- Configure asset pipeline integration properly36- Set up proper purging for production37- Use Rails helpers with Tailwind classes38- Keep build process simple3940## Utility-First Approach4142- Start with utilities before extracting components43- Use modifier classes for responsive design44- Apply state modifiers directly in HTML45- Leverage arbitrary values when needed46- Keep utility usage consistent4748## Component Patterns4950- Extract components only when truly reusable51- Use `@apply` sparingly and deliberately52- Keep extracted components simple53- Document component patterns clearly54- Prefer composition over complex components5556## Responsive Design5758- Design mobile-first always59- Use breakpoint prefixes consistently60- Test at all breakpoint sizes61- Consider touch targets on mobile62- Optimize for common device sizes6364## Color Management6566- Use Tailwind's color palette67- Define semantic color names68- Maintain consistent color usage69- Support dark mode properly70- Test color accessibility7172## Typography System7374- Use Tailwind's typography scale75- Keep font sizes consistent76- Implement proper line heights77- Use appropriate font weights78- Consider readability always7980## Spacing Guidelines8182- Use Tailwind's spacing scale exclusively83- Keep spacing consistent throughout84- Apply spacing systematically85- Use negative margins carefully86- Document spacing decisions8788## Form Styling8990- Style forms consistently with utilities91- Use focus states for accessibility92- Implement proper error states93- Keep inputs touch-friendly94- Test form usability thoroughly9596## Animation and Transitions9798- Use Tailwind's transition utilities99- Keep animations subtle and purposeful100- Implement reduced motion support101- Test animation performance102- Avoid excessive animations103104## Dark Mode Implementation105106- Design with dark mode in mind107- Use Tailwind's dark mode utilities108- Test both modes thoroughly109- Ensure sufficient contrast110- Handle images appropriately111112## Performance Optimization113114- Configure PurgeCSS correctly115- Monitor CSS bundle size116- Use JIT mode for development117- Optimize for critical CSS118- Lazy load non-critical styles119120## Accessibility Considerations121122- Ensure sufficient color contrast123- Use focus-visible for keyboard navigation124- Test with screen readers125- Implement proper ARIA attributes126- Follow WCAG guidelines127128## Rails View Integration129130- Use Tailwind classes in Rails helpers131- Keep ERB templates readable132- Apply styles consistently133- Use partials for repeated patterns134- Document styling patterns135136## Asset Pipeline Configuration137138- Configure Tailwind with Propshaft139- Set up proper build commands140- Use Rails asset helpers141- Configure for production builds142- Keep configuration simple143144## Development Workflow145146- Use Tailwind CSS IntelliSense147- Configure editor for Tailwind148- Use browser DevTools effectively149- Test across browsers150- Keep styles maintainable151152## Common Patterns153154- Card layouts with shadows155- Responsive navigation menus156- Form layouts with proper spacing157- Modal dialogs with overlays158- Data tables with hover states159160## Anti-Patterns to Avoid161162- Don't recreate utility classes163- Avoid inline styles164- Don't over-extract components165- Skip complex CSS when utilities work166- Prevent specificity battles167168## Debugging Techniques169170- Use browser DevTools171- Check compiled CSS output172- Verify purging works correctly173- Test responsive breakpoints174- Monitor specificity issues175176## Team Guidelines177178- Document custom utilities179- Share component patterns180- Maintain style consistency181- Review styling in PRs182- Keep team aligned183184## Migration Strategy185186- Convert CSS gradually187- Use Tailwind alongside existing styles188- Replace custom CSS with utilities189- Test thoroughly during migration190- Document migration decisions191192## Production Considerations193194- Optimize CSS delivery195- Use CDN for assets196- Enable compression197- Monitor performance metrics198- Cache assets appropriately199200## Best Practices Summary201202- Let utilities do the work203- Keep HTML readable204- Design systematically205- Test across devices206- Maintain consistency207208Remember: TailwindCSS provides a complete design system. Use it fully before writing custom CSS.209
One repository carrying more than one format is the comparison this product exists for: does anyone actually write different content in each file, or is one a copy of the other?
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| levifig/rails-instructions.github/instructions/rails-controllers.instructions.md · 54 | Copilot instructions | teststylesecurityapi+1 | 56/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-models.instructions.md · 54 | Copilot instructions | teststylearchtypes+4 | 60/100 | 14 days ago | |
| levifig/rails-instructions.cursor/rules/rails-rules.mdc · 54 | Cursor rules | testlint-formatstylearch+9 | 84/100 | 14 days ago | |
| levifig/rails-instructions.github/copilot-instructions.md · 54 | Copilot instructions | teststyletesting-strategysecurity+4 | 71/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-api.instructions.md · 54 | Copilot instructions | testlint-formatstyletesting-strategy+7 | 67/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-services.instructions.md · 54 | Copilot instructions | teststylearchtesting-strategy+4 | 75/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-background-jobs.instructions.md · 54 | Copilot instructions | teststyletesting-strategydatabase+2 | 63/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-core.instructions.md · 54 | Copilot instructions | teststylearchtesting-strategy+5 | 68/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-deployment.instructions.md · 54 | Copilot instructions | setupstylesecuritydatabase+2 | 52/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-hotwire.instructions.md · 54 | Copilot instructions | teststylesecurityperformance+1 | 56/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-importmaps.instructions.md · 54 | Copilot instructions | teststylesecuritydatabase+2 | 56/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-mobile.instructions.md · 54 | Copilot instructions | styleuiperformance | 66/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-performance.instructions.md · 54 | Copilot instructions | teststylegitdatabase+2 | 56/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-security.instructions.md · 54 | Copilot instructions | teststylesecuritydependencies+3 | 63/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-testing.instructions.md · 54 | Copilot instructions | teststyletesting-strategysecurity+2 | 56/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails-views.instructions.md · 54 | Copilot instructions | teststylearchsecurity+3 | 60/100 | 14 days ago | |
| levifig/rails-instructions.github/instructions/rails.instructions.md · 54 | Copilot instructions | testlint-formatstylearch+9 | 84/100 | 14 days ago | |
| levifig/rails-instructions.cursor/rules/guidelines.mdc · 54 | Cursor rules | teststyletesting-strategysecurity+4 | 71/100 | 14 days ago |
A badge carrying the measured quality of the strongest agent config file in this repository, out of 100. It reads from this index every time somebody loads your page, so it changes when the measurement changes and there is nothing to keep up to date. Free, no account, and the value is not something you or we can set by hand.
[](https://rulestack.kynth.studio/configs/levifig-rails-instructions-github-instructions-rails-styling-instructions)Would rather not hotlink us? Every badge is also served in shields.io’s endpoint schema, so shields renders the image and your readers never talk to our domain:
Published by Toolproof, the masthead over this index and eight others. The method behind the number is at toolproof.kynth.studio/methodology, and the whole thing is readable as JSON with no key at /api.