add: readmes and boilerplate

This commit is contained in:
2026-03-24 19:59:30 -07:00
commit 3df04e4cb6
26 changed files with 14122 additions and 0 deletions
+35
View File
@@ -0,0 +1,35 @@
# Development guide
## Backend/Golang
Do not alter go.mod directly, instead, use the CLI tools `go mod tidy`, `go mod
init`, and so forth.
Write tests for all public APIs. Never test a private API; if it feels like we
need to do that, refactor the code to make the difficult-to-test part a new
package.
Prefer to write clear function and variables names over comments. In general,
avoid writing comments when the same logic can be communicated with code.
Follow https://github.com/golang-standards/project-layout/blob/master/README.md
for layout
The main function should be very small.
Prefer to test with real implementations rather than mocks. For example, bring
up a real HTTP server to test.
Generally conform to resource-oriented design describe in
https://google.aip.dev/general.
## Frontend/Typescript
Do not alter package.json directly, instead, use the CLI tool `npm`.
Write unit tests for all exported APIs. Never test private APIs. If it feels
like we need to test private methods, refactor the code to make the
difficult-to-test part of a new package.
Prefer to keep the front-end code minimal. If there is a need to transform data,
do that on the backend, and add a new API to load the transformed data.