docs: add frontend development guidelines

This commit is contained in:
que01 committed 2026-08-26 15:29:11 +08:00
1 parent f7601d554e
commit faaa33717f
8 files changed
+213

No files matched your search

@@ -0,0 +1,5 @@
# Component Guidelines
Use typed React function components. `App.tsx` owns session/editor composition, while reusable map and UI concerns live in named components. Prefer the shared `ui/button.tsx` primitive for commands. Do not create business UI with `querySelector` or `innerHTML`.
Forms use controlled inputs and submit handlers. Keep map canvas DOM owned by OpenLayers and surrounding controls owned by React.