返回文章列表

断舍离进行时:从功能膨胀到做减法

2 分钟阅读

背景

这周主要做了两件事:清理了一些前端菜单项,以及修正了文档中关于 pnpm doctor 的描述。看起来都是"小打小闹",但背后其实反映了一个值得聊聊的问题——功能膨胀后的断舍离。

做了什么

1. 移除「技能管理」和「博客统计」菜单

这两个入口曾经也是"规划中"的功能,后来随着系统演进逐渐边缘化。与其让它们占着地方,不如直接移除,保持界面简洁。

改动涉及:

  • menuConfig.ts - 移除两个 MenuItem 定义
  • TaskManagementPage.tsx - 优化任务删除的确认对话框
  • task.ts - 简化 deleteTask 的返回值处理

2. 修正 pnpm doctor 文档

之前文档里对 pnpm doctor 的描述有些模糊,这次统一了各处的说法,避免误导。

反思:断舍离的代价

Gemini 毒舌点评:

所谓"文档演化":不过是在给屎山涂改说明书 把"移除歧义"说得这么好听,本质上就是你当初根本没搞清楚这个命令在 CI 环境里到底在干嘛,随手一贴发现报错成灾,现在才回来像个勤勉的保洁员一样擦屁股。

说得难听但有理。文档和代码一样是需要迭代的,区别在于代码报错会立刻让你知道疼,文档写错可能几年都没人发现。

功能大裁员:承认吧,你根本 Hold 不住 这两个菜单项当初上线时吹得天花乱坠,现在悄悄删掉,说明你对"长期主义"的认知仅限于三分钟热度。

确实,很多功能上线时信心满满,后来就变成了"食之无味弃之可惜"的鸡肋。与其留着占坑,不如早点砍掉。

总结

这周没有做什么"大动作",但"做减法"也是一种进步。系统不是功能越多越好有时候,知道什么该删,比知道什么该加更重要。


English Version

The Art of Subtraction: When Less Becomes More

This week wasn't about adding new features—it was about removing dead weight. Two menu items ("Skill Management" and "Blog Stats") were cleaned up, and documentation around pnpm doctor was clarified.

Why it matters:

Every feature that's left "for future use" is a mental tax on developers and users. The system gets cluttered, the codebase gets bloated, and eventually you have a maze of half-implemented functionality.

The hard truth (via Gemini):

You spent 80% of your time on GitHub Actions and deployment scripts, only 20% on actual business logic. You're not building a product—you're playing "simulated system admin."

That's a brutal but fair assessment. We've been guilty of over-automation and over-engineering. Sometimes a simple cron job beats a fancy distributed queue. Sometimes no feature beats a "planned" feature.

Takeaway:

The best code is the code you don't write. The best feature is the one you removed before it became technical debt.

Keep cutting. Keep simplifying.

觉得有帮助?请我喝杯咖啡

如果这篇文章对你有所帮助,欢迎扫码支持作者继续创作更多优质内容。

微信
微信
支付宝
支付宝

评论