Skip to content

Commit d56ee0d

Browse files
committed
docs: refine CONTRIBUTIONS.md
1 parent 68a649b commit d56ee0d

1 file changed

Lines changed: 26 additions & 98 deletions

File tree

CONTRIBUTING.md

Lines changed: 26 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -11,29 +11,40 @@ pnpm install
1111
# Build all packages
1212
pnpm build
1313

14-
# Run tests
14+
# Run tests (both browser and unit tests)
1515
pnpm test
1616

17-
# Run dev mode (watches for changes)
17+
# Run dev mode (watches for changes and rebuilds all packages)
1818
pnpm dev
1919

20+
# Run the demo application
21+
pnpm demo
22+
2023
# Lint and format code
21-
pnpm run lint
22-
pnpm run lint:fix
23-
pnpm run format
24+
pnpm oxlint
25+
pnpm oxlint --fix
26+
pnpm oxfmt
2427
```
2528

29+
I usually run `pnpm demo` in parallel to `pnpm dev`.
30+
2631
## Making Changes
2732

2833
1. Create a branch from `main`
2934
2. Make your changes in the relevant package under `packages/`
3035
3. Add tests if applicable
31-
4. Ensure code passes linting: `pnpm run lint`
36+
4. Ensure code passes linting: `pnpm oxlint`
3237
5. Run tests: `pnpm test`
38+
6. [optional] add changeset
39+
7. open a PR
40+
41+
> Please provide a description of the intended change in the PR.
42+
43+
> Commit messages should follow [convential commit standard](https://www.conventionalcommits.org/en/v1.0.0/)
3344
34-
## Versioning with Changesets
45+
## Versioning
3546

36-
This monorepo uses [changesets](https://github.com/changesets/changesets) for managing independent package versions and changelogs.
47+
This monorepo uses [semantic versioning](https://semver.org). Package versions are managed with [changesets](https://github.com/changesets/changesets) for independent package versions and changelogs.
3748

3849
### Creating a Changeset
3950

@@ -43,111 +54,28 @@ After making changes, create a changeset:
4354
pnpm changeset
4455
```
4556

46-
This will prompt you to:
47-
48-
1. **Select affected packages** - Choose which packages were modified
49-
2. **Select version bump** - Choose between:
50-
- `patch` - Bug fixes (0.0.X)
51-
- `minor` - Features (0.X.0)
52-
- `major` - Breaking changes (X.0.0)
53-
3. **Write summary** - Describe your changes for the changelog
54-
55-
Example:
56-
57-
```
58-
✔ Which packages would you like to include? … @vingy/vuebugger
59-
✔ Which packages should have a MAJOR bump? … no
60-
✔ Which packages should have a MINOR bump? … @vingy/vuebugger
61-
✔ Write a summary for this change: Added support for custom options
62-
63-
Summary: Added support for custom options
64-
```
65-
6657
This creates a file in `.changeset/` (e.g., `.changeset/brave-lions-enjoy.md`). Commit this file with your changes.
6758

68-
### Before Publishing
69-
70-
The maintainers will handle versioning and publishing:
71-
72-
```bash
73-
# Update package versions based on changesets
74-
pnpm changeset:version
75-
76-
# This will:
77-
# - Update all package.json versions
78-
# - Create/update CHANGELOG.md files
79-
# - Consume all changesets
80-
# - Create a version commit
81-
82-
# Review the changes, then publish
83-
pnpm changeset:publish
84-
85-
# This will:
86-
# - Build all packages
87-
# - Publish to npm
88-
# - Create git tags (e.g., @vingy/vuebugger@1.0.0)
89-
# - Push tags to GitHub
90-
```
91-
92-
## Package Structure
93-
94-
```
95-
packages/
96-
├── vuebugger/ # Vue devtools plugin
97-
├── vueltip/ # Headless tooltip component
98-
└── [your-package]/ # New packages follow the same structure
99-
├── src/
100-
├── package.json
101-
├── tsconfig.json
102-
└── tsdown.config.ts
103-
```
104-
105-
Each package:
106-
107-
- Has independent versioning via changesets
108-
- Uses the shared tooling (TypeScript, vitest, oxlint, oxfmt)
109-
- Publishes to npm with `@vingy` scope
110-
- Is linked in the workspace via `pnpm` for local development
111-
112-
## Publishing New Packages
113-
114-
Initial publish (manual):
115-
116-
```bash
117-
pnpm --filter @vingy/your-package publish --access public
118-
```
119-
120-
Future updates use changesets (see "Before Publishing" section above).
121-
122-
## Guidelines
123-
12459
- **No changesets needed for:**
12560
- Documentation changes
12661
- CI/CD workflow updates
12762
- README changes
128-
- Dependency updates (these auto-bump if a package changes)
12963

13064
- **Always create changesets for:**
131-
- Code changes affecting any package
65+
- Code changes affecting the bundle
13266
- API additions or changes
13367
- Bug fixes
13468

13569
## Code Quality
13670

137-
All code is checked with:
138-
139-
- **oxlint** - JavaScript/TypeScript linting
140-
- **oxfmt** - Code formatting
141-
- **vitest** - Unit tests
142-
- **TypeScript** - Type checking
71+
Code quality is checked automatically in CI.
14372

144-
Run before committing:
73+
## Project Structure
14574

146-
```bash
147-
pnpm run lint # Check for issues
148-
pnpm run lint:fix # Fix formatting
149-
pnpm test # Run tests
150-
```
75+
- `packages/shared/` - Shared types and utilities
76+
- `packages/vuebugger/` - Vue debugging utilities
77+
- `packages/vueltip/` - Vue tooltip components/composables
78+
- `demo/` - Demo application for testing packages
15179

15280
## Questions?
15381

0 commit comments

Comments
 (0)