Files
hnh-map/CONTRIBUTING.md
Nikolay Tatarinov 605a31567e Add initial project structure with backend and frontend setup
- Created backend structure with Go, including main application logic and API endpoints.
- Added Docker support for both development and production environments.
- Introduced frontend using Nuxt 3 with Tailwind CSS for styling.
- Included configuration files for Docker and environment variables.
- Established basic documentation for contributing, development, and deployment processes.
- Set up .gitignore and .dockerignore files to manage ignored files in the repository.
2026-02-24 22:27:05 +03:00

1.4 KiB

Contributing to hnh-map

Getting started

Clone the repository and run the project locally (see Development):

  • Option A: Docker Compose for development: docker compose -f docker-compose.dev.yml up (frontend on 3000, backend on 3080).
  • Option B: Run Go backend from the repo root (go run ./cmd/hnh-map -grids=./grids -port=8080) and Nuxt separately (cd frontend-nuxt && npm run dev). Ensure the frontend can reach the backend (proxy or same host).

Code layout

  • Backend: Entry point is cmd/hnh-map/main.go. All application logic lives in internal/app/ (package app): app.go (App, types, routes, session helpers), api.go, admin.go, client.go, map.go, tile.go, topic.go, manage.go, migrations.go. The webapp/ package in the repo root handles HTML template loading and execution.
  • Frontend: Nuxt 3 app in frontend-nuxt/ (pages, components, composables, layouts, server, plugins, public/gfx). It is served by the Go backend under /map/ with baseURL /map/.

Formatting and tests

  • Go: run go fmt ./... before committing.
  • Add or update tests if you change behaviour; run go test ./... if tests exist.

Submitting changes

  • Open a pull request with a clear description of the change.
  • Mention compatibility with hnh-auto-mapper-server if relevant (e.g. client protocol or API).