code-quality by tursodatabase/turso
npx skills add https://github.com/tursodatabase/turso --skill code-quality生产数据库。正确性至上。崩溃优于损坏。
错误示例:
if condition {
// happy path
} else {
// "shouldn't happen" - silently ignored
}
正确示例:
// 如果只应命中一个分支:
assert!(condition, "invariant violated: ...");
// 或者
return Err(LimboError::InternalError("unexpected state".into()));
// 或者
unreachable!("impossible state: ...");
仅当两个分支都是预期路径时才使用 if 语句。
应该:
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
不应该:
当代码涉及索引插入、删除或冲突解决时,请对照 SQLite 仔细检查顺序。错误的顺序会导致索引不一致,并且很容易被忽略。
_vars、重新导出、// removed 注释)每周安装量
709
代码仓库
GitHub 星标数
17.9K
首次出现
2026 年 1 月 28 日
安全审计
安装于
claude-code497
github-copilot464
opencode423
codex408
gemini-cli407
cursor352
Production database. Correctness paramount. Crash > corrupt.
Wrong:
if condition {
// happy path
} else {
// "shouldn't happen" - silently ignored
}
Right:
// If only one branch should ever be hit:
assert!(condition, "invariant violated: ...");
// OR
return Err(LimboError::InternalError("unexpected state".into()));
// OR
unreachable!("impossible state: ...");
Use if-statements only when both branches are expected paths.
Do:
Don't:
When code involves index inserts, deletes, or conflict resolution, double-check the ordering against SQLite. Wrong ordering causes index inconsistencies. and easy to miss.
_vars, re-exports, // removed comments)Weekly Installs
709
Repository
GitHub Stars
17.9K
First Seen
Jan 28, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
claude-code497
github-copilot464
opencode423
codex408
gemini-cli407
cursor352
React 组合模式指南:Vercel 组件架构最佳实践,提升代码可维护性
103,800 周安装