vafast 0.4.19 → 0.4.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +33 -1
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -633,7 +633,9 @@ console.log(`P99: ${status.p99}ms, RPS: ${status.rps}`);
633
633
 
634
634
  ```typescript
635
635
  import { serve } from 'vafast';
636
- serve({ fetch: server.fetch, port: 3000 });
636
+ serve({ fetch: server.fetch, port: 3000 }, (info) => {
637
+ console.log(`🚀 Server running at http://localhost:${info.port}`);
638
+ });
637
639
  ```
638
640
 
639
641
  > 💡 `serve` 函数兼容 Bun 和 Node.js,代码无需修改即可跨运行时
@@ -668,6 +670,36 @@ npm install # 或 bun install
668
670
  npm test # 或 bun test
669
671
  ```
670
672
 
673
+ ## 🚀 发布流程
674
+
675
+ **一条命令完成发布:**
676
+
677
+ ```bash
678
+ npm run release
679
+ ```
680
+
681
+ **自动完成:**
682
+ 1. ✅ `bumpp` 交互式选择版本(patch/minor/major)
683
+ 2. ✅ 更新 `package.json` 版本号
684
+ 3. ✅ 创建 git commit + tag
685
+ 4. ✅ 推送到 GitHub
686
+ 5. ✅ GitHub Actions 自动触发:
687
+ - 构建 + 测试
688
+ - `changelogithub` 生成 Release Notes
689
+ - 创建 GitHub Release
690
+ - 发布到 npm(Trusted Publishing)
691
+
692
+ **Commit 规范(用于生成 changelog):**
693
+
694
+ ```bash
695
+ feat: 新增功能 # → 🚀 Features
696
+ fix: 修复问题 # → 🐛 Bug Fixes
697
+ docs: 更新文档 # → 📝 Documentation
698
+ perf: 性能优化 # → ⚡ Performance
699
+ refactor: 重构 # → ♻️ Refactors
700
+ chore: 杂项 # → 🏠 Chores
701
+ ```
702
+
671
703
  ## 📄 许可证
672
704
 
673
705
  [MIT](./LICENSE)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vafast",
3
- "version": "0.4.19",
3
+ "version": "0.4.21",
4
4
  "description": "极简结构化Web框架,支持 Bun 和 Node.js。Go风格,函数优先。",
5
5
  "type": "module",
6
6
  "repository": {