从规范自动生成浏览器引擎
推荐指数 59.0 NO. 020 · 2026.10.02
发布2026/10/01Score75Comments20
为什么值得看
Bez 尝试用 Web 标准和 WPT 测试用例自动生成完整的浏览器渲染引擎,而非手写代码。若成功,将打破 Chromium/WebKit/Gecko 三家垄断,让定制轻量化引擎成本趋近于零。
编辑判断
浏览器引擎是软件工程中最复杂的项目之一,Servo 花了 Mozilla 十年仍未成熟,Ladybird 靠众筹硬啃 C++。Bez 的激进之处在于不手写实现,而是把规范当源语言、把三家浏览器的一致性当 ground truth 做验证,本质是用形式化方法解决工程债务。
但风险同样明显:CSS 规范有大量未定义行为和遗留怪癖(quirks mode),纯 spec-driven 能否覆盖真实网页存疑。WPT 覆盖率虽高,漏掉的 edge case 正是兼容性噩梦的来源。
最该关注的不是做浏览器的团队,而是嵌入式 WebView 和跨平台框架(Flutter、Tauri、Electron)的维护者——如果 Bez 的 tree-shaking 能做到"分析你的 HTML/CSS 子集,只编译需要的渲染管线",这些场景的性能和包体积将迎来质变。建议先跟踪其 content-scoped-engine 的实测数据。
社区反馈
意见分歧 20 条评论
核心争论:规范自动生成浏览器引擎理论上可行,但实践中面临规格非机器可读、性能优化、安全架构等深层挑战
I'm looking forward to the day when we have fully functioning web browsers that we have full programmatic control over in all aspects. With luck all chromium/blink-based browsers will go the way of the dodo bird.
I'm afraid internally they would still look like chromium/blink anyway.
This makes a ton of sense to me with the huge corpus of web standards that exist. In theory we should be able to generate a browser from those specs, it just took a massive amount of effort before. Maybe if things like this get some traction, some of the human time spent implementing the spec could