搜索

PythonReactSEOPDF
GitHub Skill

fix-css

Fixes corrupted Panda CSS styled-system when styles appear broken, CSS isn't applying, or the build fails with styled-system errors. Use when CSS looks wrong, styles are missing, or after prettier/formatters may have corrupted generated files.

antialias☆ 0 仓库 Stars0 仓库 Forks

安装与使用

请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。

查看来源 ↗使用指南

技能说明

Fix Corrupted Panda CSS (styled-system)

This project uses Panda CSS which generates a styled-system/ directory. This directory can become corrupted when:

  • Prettier or other formatters modify the generated files
  • Git merge conflicts in styled-system/
  • Interrupted panda codegen runs
  • Node modules corruption

Symptoms

  • Styles not applying correctly
  • CSS appears broken or missing
  • Build errors mentioning styled-system
  • Type errors in styled-system/ imports
  • Visual regressions that appeared without code changes

Fix Procedure

Run these commands in order:

# 1. Delete the corrupted styled-system
rm -rf apps/web/styled-system

# 2. Regenerate it with Panda CSS
cd apps/web && pnpm panda codegen

# 3. Clear Next.js cache (if build errors persist)
rm -rf apps/web/.next

# 4. Rebuild to verify
cd /Users/antialias/projects/soroban-abacus-flashcards && pnpm build

Verification

After regeneration, verify:

  1. apps/web/styled-system/ directory exists with fresh files
  2. pnpm build completes without styled-system errors
  3. Dev server shows correct styling

Prevention

The repo has .prettierignore at the root that excludes **/styled-system/**. If corruption keeps happening:

  1. Verify .prettierignore contains **/styled-system/**
  2. Check that IDE formatters respect .prettierignore
  3. Ensure git hooks don't format styled-system files

Quick One-Liner

For fast fix without explanation:

rm -rf apps/web/styled-system apps/web/.next && cd apps/web && pnpm panda codegen && cd ../.. && pnpm build

使用示例

查看来源仓库中的使用示例与配置说明。

查看来源 ↗

来源历史

收录时间
2026-01-20
索引更新时间
2026-01-26
Branch
main

收录与同步日期属于本站记录。源码修改历史请查看来源仓库。

GitHub ↗

chat Comments (0)

chat_bubble_outline

No comments yet. Be the first to share your thoughts!