From 20798eb8a6ec7207845d98b4dad9ad24a70619b6 Mon Sep 17 00:00:00 2001 From: torn4dom4n <27698189+torn4dom4n@users.noreply.github.com> Date: Thu, 2 Jul 2026 16:23:25 +0000 Subject: [PATCH] docs: add Rust migration research findings to AGENTS.md Documented performance benchmarks and trade-offs of migrating TypeScript utilities to Rust. Findings show that while Rust is faster (~15ms vs ~100ms), the gains are negligible in CI environments and do not outweigh the maintenance and distribution complexity. Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com> --- AGENTS.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/AGENTS.md b/AGENTS.md index 3dc5473..812ee14 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -18,3 +18,12 @@ Docs are local at `node_modules/vite-plus/docs` or online at https://viteplus.de - [ ] If setup, runtime, or package-manager behavior looks wrong, run `vp env doctor` and include its output when asking for help. + +## Rust Migration Research + +In response to inquiries about migrating these TypeScript utilities to Rust for performance: + +- **Findings:** A Rust proof-of-concept for `detect-env` showed execution times of ~15ms compared to ~100ms for the TypeScript/Node.js version. +- **Conclusion:** The ~85ms saving is negligible in the context of typical CI workflows (which run for minutes). +- **Trade-offs:** Migrating would introduce significant complexity in cross-platform binary distribution and maintenance. +- **Recommendation:** Retain the TypeScript implementation for ease of maintenance and alignment with the Vite+ ecosystem.