Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 53 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Contributing

Map Printer exports print-resolution PNGs of a map area entirely in the
browser. It is a static site (Vite + TypeScript, Lit + Tailwind, maplibre-gl).

## Getting set up

You'll need Node 22. Then:

```bash
npm install
npm run dev
```

This starts the Vite dev server.

## Where things live

Each module lives under `src/lib/<name>/`, with `index.ts` as its only public
surface — nothing outside the module should import from anything else inside
it. Each module's contract (what it takes, what it returns, its invariants)
is documented in `docs/architecture.md`. UI code lives in `src/`.

## Before opening a PR

Run:

```bash
npm run typecheck
npm test # Vitest unit tests, alongside the code as src/lib/**/*.test.ts
```

Browser-only modules are covered by Playwright e2e tests in `e2e/`. Install
the browsers once with `npm run test:e2e:install`, then run them with:

```bash
npm run test:e2e
```

CI runs typecheck, unit tests, build, and the chromium + webkit e2e tests on
every push and PR.

## PRs and commits

Commit and PR titles follow [Conventional
Commits](https://www.conventionalcommits.org/): `<type>(<optional scope>):
<subject>`.

Keep PRs small and focused on one change. If a PR changes a module's
contract, update `docs/architecture.md` to match.

For anything bigger than a small fix, please open an issue first to discuss
the approach before doing the work.
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 Awana Digital

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.