Skip to content

Commit 756d0be

Browse files
authored
chore: add contributing file
2 parents 0cf401f + 5436616 commit 756d0be

2 files changed

Lines changed: 47 additions & 2 deletions

File tree

CONTRIBUTING.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Contribution guide
2+
3+
> This guide applies to **litestar.dev** — the marketing and community website
4+
> for the Litestar framework. To contribute to the framework itself, see
5+
> [`litestar-org/litestar/CONTRIBUTING.rst`](https://github.com/litestar-org/litestar/blob/main/CONTRIBUTING.rst).
6+
7+
## Setup
8+
9+
1. Install [Node.js 24](https://nodejs.org/).
10+
2. Enable Corepack so the pinned `pnpm` version is used: `corepack enable`.
11+
3. Install dependencies: `pnpm install`.
12+
13+
## Workflow
14+
15+
1. Fork and clone the repo, then create a branch.
16+
2. `pnpm dev` — dev server at http://localhost:3000.
17+
3. `pnpm format && pnpm lint && pnpm test-all` before pushing (mirrors CI).
18+
4. Open a PR with a descriptive title referencing any related issue.
19+
20+
## Tests
21+
22+
| Project | Command | Purpose |
23+
| ------- | ----------------- | ------------------------------------------------------------- |
24+
| `unit` | `pnpm test-unit` | Pure-function tests (helpers, composables) |
25+
| `nuxt` | `pnpm test-nuxt` | Tests needing the Nuxt runtime |
26+
| `build` | `pnpm test-build` | Post-build smoke tests — run **after** `pnpm generate-github` |
27+
28+
`pnpm test-all` runs `unit` + `nuxt`.
29+
30+
## Content
31+
32+
Drop a Markdown / YAML file in the right place — `nuxt generate` picks it up.
33+
34+
| Add | Where |
35+
| ------------------ | ------------------------------------------------ |
36+
| Blog post | `content/blog/` |
37+
| Sponsor | `content/sponsors/` |
38+
| Starter / template | `content/starters/` or `content/templates/` |
39+
| Page copy | `content/*.yml` (schemas in `content.config.ts`) |
40+
41+
## UI changes
42+
43+
For anything visual, run `pnpm dev` and check dark mode + mobile width. Run
44+
`pnpm generate-github` to catch SSR / prerender / OG-image errors that only
45+
appear at build time.

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ The site is automatically deployed to GitHub Pages via GitHub Actions when chang
3333
pnpm generate
3434
```
3535

36-
## Testing
36+
## Contributing
3737

38-
TODO
38+
See [CONTRIBUTING.md](./CONTRIBUTING.md) for setup, workflow, tests, and how to add content.
3939

4040
## Inspiration
4141

0 commit comments

Comments
 (0)