Skip to content

CmdWise Tech Stack Analysis & Choices

Purpose

This article captures the thinking behind CmdWise’s technology choices for frontend – docs – backend – deployment, making future maintenance and expansion easier.

1. Frontend Website

1.1 Stack

GoalSolution
Page renderingPure HTML + JavaScript + Tailwind CSS
IconsLucide
Light/Dark themeTailwind Dark Mode

Why not Vue / React?

  1. Startup speed: Static HTML previews instantly without a build step—great for rapid iteration.
  2. Learning cost: I hadn’t used Vue/React for a while; getting back up to speed would take time.
  3. AI-friendly: LLMs generate plain HTML snippets more reliably, which can be saved and used right away.

1.2 Workflow

  1. Design styles based on ui-style-guide.
  2. Use index.html as a reference and let Cursor generate each page.
  3. Manually tweak details to ensure consistency.

1.3 Deployment (Cloudflare Pages)

bash
wrangler deploy --minify
  • After deploy, bind a custom domain to obtain HTTPS automatically, no manual certificates.
  • Static site → zero server cost.

2. Docs

2.1 Tooling

  • VitePress: supports Chinese/English switching.
  • Follow SEO & editorial style rules, with AI helping layout and polishing.

2.2 Flow

  1. Decide directory structure → configure VitePress.
  2. Ask AI to review for rationality.
  3. Write Chinese draft → polish for SEO → manual review → AI generates English version.

3. Backend Server

3.1 Framework

  • Hono — natively integrates with Cloudflare Workers and provides LLM helper docs, so AI tools can read API specs and generate code easily.

3.2 Cloud Services

FeatureService
RuntimeCloudflare Workers
DatabaseD1 (SQLite)
Object StorageR2

Choosing the Cloudflare family—Workers + D1 + R2—means one-line configuration, almost zero ops.

3.3 Local Development

  • wrangler dev spins up local D1 & R2 under .wrangler/state and supports breakpoint debugging, almost like a local Node server.
  • You can open D1 with any SQLite GUI; the Cloudflare console also shows data, but the browser plugin Drizzle Studio feels smoother.

3.4 Deployment Notes

bash
wrangler deploy --minify
  • Just add a wrangler.jsonc or wrangler.toml at root, then run the command above.
  • Add keep_vars = true in wrangler.toml to avoid env vars being reset on deploy.
  • For secrets, wrangler secret is faster than pasting in the Dashboard (though the Dashboard now supports multi-line paste too).

4. Desktop App

Options: Electron vs Tauri

MetricElectronTauri
Community & ecosystem★★★★★★★★★☆
Cross-platformmacOS / Windows / LinuxSame
Debug experienceMatureNewer

After weighing needs, AI (Cursor) chose Electron + React.

Why:

  1. Electron has a mature ecosystem with plenty of examples; its footprint in AI training data is large, so code generation is easier.
  2. React + Electron is a proven combo with lots of community cases, reducing the risk of pitfalls.

5. Conclusion

Using the Cloudflare stack plus a simple frontend keeps deployment cheap and development fast. With AI, we can validate ideas quickly and iterate continuously.