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
28 changes: 28 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: Bug report
about: Something doesn't behave the way it should
labels: bug
---

## SSCCE

A **Short, Self-Contained, Correct (Compilable) Example** — the smallest
component usage that still reproduces the bug, with nothing to install or
assume. Paste it as a single block; we should be able to copy it, run it,
and see the bug with zero edits.

```tsx
// paste your minimal repro here
```

## Expected

What you expected it to do.

## Actual

What it actually did.

## Version

- `@dunky-dev/*` package and version:
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
blank_issues_enabled: true
11 changes: 11 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Why/What

<!-- Why this change, and what it does — a sentence or two. -->

# Changes

<!-- The change itself, in a few words. -->

# Issues

<!-- Link related issues, e.g. Closes #123 -->
76 changes: 76 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Contributing

For the contribution _workflow_, code conventions, and boundaries, see [`AGENTS.md`](./AGENTS.md) — it's the same
contract agents follow here, and it applies to you too.

## Setup

```bash
git clone git@github.com:dunky-dev/ui.git
cd ui
nvm use
corepack enable
pnpm install
```

## Commands

| Command | What it does |
| ------------------------------- | ---------------------------------------------------------- |
| `pnpm test` | Full test suite, watch mode |
| `pnpm typecheck` | `tsc --noEmit` across the whole workspace |
| `pnpm lint` | `oxlint` |
| `pnpm format` / `format:check` | `oxfmt` |
| `pnpm knip` | Unused exports/dependencies |
| `pnpm changeset` | Add a changeset — see [Versioning](./AGENTS.md#versioning) |

Target one package or one file instead of the whole workspace:

```bash
pnpm --filter @dunky-dev/core test
pnpm test packages/core/src/some-file.test.ts
```

## Storybook

Each UI substrate (React, Vue, ...) is a self-contained package under
`packages/<substrate>` with its own Storybook — the fastest way to see a
change actually render. `pnpm dev` delegates to the substrate's package via
`scripts/sb.js`:

```bash
pnpm dev # @dunky-dev/react Storybook, defaults to http://localhost:6006
pnpm dev vue # once packages/vue exists
pnpm build-storybook # static build of the react substrate's Storybook
```

## Filing an issue

A bug report is only as useful as its reproduction. Use an **SSCCE** — Short,
Self-Contained, Correct (Compilable) Example:

- **Short** — the smallest snippet that still reproduces it. Strip every
prop, wrapper, and state change that isn't load-bearing.
- **Self-contained** — no missing imports, no "assume you have X set up."
Someone should be able to paste it and run it with nothing else.
- **Correct (compilable)** — it actually runs and actually reproduces the
bug. Not what you _think_ is happening — what you pasted and ran.

The [bug report template](.github/ISSUE_TEMPLATE/bug_report.md) asks for
exactly this. If you can't shrink your repro to an SSCCE, that's often a sign
the bug isn't where you think it is — shrinking it is frequently how you find
the real cause yourself.

## Pull requests

### Humans

When using AI to help write changes, read the diff like you wrote it yourself
before asking someone else to. Cut comments that don't say anything, drop
anything that drifted from what you're actually fixing, and be able to
explain any line if asked. A reviewer's time isn't free.

### AI

Before opening it, make sure tests, lint, and typecheck pass, and a changeset is
included — see `AGENTS.md`'s Workflow section.
Loading