Install any skill in seconds. Free to start, no credit card required.
Get Started Free →当 cook-web 需要调整 Next.js App Router 全局或路由级错误兜底页时使用本技能。错误页应直接展示错误名称、message、digest、cause、URL 和可用 stack,避免只提示用户查看控制台。
.claude/skills/ai-shifu-app-error-boundary-display/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-08 | ✗→✓ | ▲ Improved | -20% | 0% |
| case-01 | ✗→✓ | ▲ Improved | 32% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 1% | 0% |
| case-03 | ✗→✓ | ▲ Improved | 1% | 0% |
| case-06 | ✗→✓ | ▲ Improved | 1% | 0% |
src/app/error.tsx 和 src/app/global-error.tsx;前者处理路由段错误,后者处理根布局或更外层错误。name、message、digest、cause、当前 URL;有 stack 时可截断后直接展示,便于截图定位。global-error.tsx 需要自己返回 <html> 和 <body>,不要依赖根布局里的 Provider、i18n 或运行时配置已经初始化。@/store barrel,避免错误页加载时触发 unrelated store 的模块副作用。dvh,不要使用 vh 或 env(safe-area-inset-bottom)。src/app/error.tsx 与 src/app/global-error.tsx。window、document 或触发 store 初始化副作用。npm run type-check,确认 App Router 特殊文件签名和 client component 类型通过。| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-10 | pass→pass | 13,537 | 6,188 | -54% | 1 | 1 | 0% | 2,103 | 1,510 | -28% | 0 | 0 | — |
case-08 | fail→pass | 12,929 | 5,536 | -57% | 1 | 1 | 0% | 1,960 | 1,567 | -20% | 0 | 0 | — |
case-09 | pass→pass | 10,340 | 14,224 | +38% | 1 | 1 | 0% | 1,996 | 3,264 | +64% | 0 | 0 | — |
case-01 | fail→pass | 20,733 | 24,130 | +16% | 1 | 1 | 0% | 4,127 | 5,430 | +32% | 0 | 0 | — |
case-02 | fail→pass | 19,801 | 18,248 | -8% | 1 | 1 | 0% | 3,985 | 4,017 | +1% | 0 | 0 | — |
case-03 | fail→pass | 22,496 | 19,231 | -15% | 1 | 1 | 0% | 4,329 | 4,352 | +1% | 0 | 0 | — |
case-04 | pass→pass | 12,928 | 17,092 | +32% | 1 | 1 | 0% | 2,092 | 3,826 | +83% | 0 | 0 | — |
case-05 | pass→pass | 13,426 | 7,620 | -43% | 1 | 1 | 0% | 2,244 | 1,729 | -23% | 0 | 0 | — |
case-06 | fail→pass | 13,055 | 9,468 | -27% | 1 | 1 | 0% | 2,165 | 2,178 | +1% | 0 | 0 | — |
case-07 | pass→pass | 11,109 | 3,244 | -71% | 1 | 1 | 0% | 1,947 | 1,058 | -46% | 0 | 0 | — |
case-11 | fail→pass | 13,311 | 13,580 | +2% | 1 | 1 | 0% | 2,214 | 2,992 | +35% | 0 | 0 | — |
case-12 | fail→pass | 12,991 | 5,014 | -61% | 1 | 1 | 0% | 1,814 | 1,245 | -31% | 0 | 0 | — |
case-13 | fail→pass | 7,989 | 2,877 | -64% | 1 | 1 | 0% | 1,238 | 931 | -25% | 0 | 0 | — |
case-14 | pass→pass | 11,333 | 12,781 | +13% | 1 | 1 | 0% | 2,006 | 2,874 | +43% | 0 | 0 | — |
case-15 | pass→pass | 12,332 | 9,778 | -21% | 1 | 1 | 0% | 2,022 | 1,993 | -1% | 0 | 0 | — |
case-16 | fail→pass | 8,286 | 8,743 | +6% | 1 | 1 | 0% | 1,395 | 1,819 | +30% | 0 | 0 | — |
case-17 | pass→pass | 10,188 | 3,349 | -67% | 1 | 1 | 0% | 1,684 | 931 | -45% | 0 | 0 | — |
case-18 | pass→pass | 11,808 | 14,802 | +25% | 1 | 1 | 0% | 2,173 | 3,261 | +50% | 0 | 0 | — |
case-19 | pass→pass | 8,576 | 6,849 | -20% | 1 | 1 | 0% | 1,515 | 1,720 | +14% | 0 | 0 | — |
case-20 | pass→pass | 12,953 | 10,147 | -22% | 1 | 1 | 0% | 2,214 | 2,370 | +7% | 0 | 0 | — |
case-21 | pass→pass | 14,403 | 17,021 | +18% | 1 | 1 | 0% | 2,617 | 3,715 | +42% | 0 | 0 | — |
case-22 | pass→pass | 13,487 | 13,257 | -2% | 1 | 1 | 0% | 2,440 | 2,866 | +17% | 0 | 0 | — |
case-23 | pass→pass | 10,845 | 16,975 | +57% | 1 | 1 | 0% | 1,903 | 2,549 | +34% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 23 cases were attempted. The headline lift of +39 percentage points is the difference between those two pass rates over the 23 comparable cases.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.