You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .claude/commands/changeset.md
+11-26Lines changed: 11 additions & 26 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -44,12 +44,22 @@ The frontmatter is enclosed by ---` lines. It lists each affected package and it
44
44
**Important Note on SemVer Bumping and Multiple Changesets:**
45
45
46
46
- Each distinct change (breaking, feature, fix) for a package **MUST** have its own changeset file.
47
+
- A single changeset file **MUST** contain only ONE package in its frontmatter.
47
48
- For example, if you make a breaking API change, add a new feature, and fix a bug in `@platejs/core` for an upcoming release, you will create **three separate changeset files**:
48
49
1. One file marked `major` for `@platejs/core` detailing only the breaking change.
49
50
2. One file marked `minor` for `@platejs/core` detailing only the new feature.
50
51
3. One file marked `patch` for `@platejs/core` detailing only the bug fix.
51
52
- The versioning tool will look at all pending changesets for a package. If there's at least one `major` file, the package gets a major version bump, and all changes (from major, minor, and patch files) are included in that release. If no `major` but at least one `minor`, it gets a minor bump, and so on.
52
53
54
+
**Example: Multiple Changes, Multiple Packages**
55
+
56
+
- If a PR adds a `minor` feature to `@platejs/core` and a `patch` fix to `@platejs/utils`, you MUST create TWO separate files:
57
+
58
+
1.`core-minor.md` (containing only `'@platejs/core': minor`)
59
+
2.`utils-patch.md` (containing only `'@platejs/utils': patch`)
60
+
61
+
- If a PR adds `minor` features to both `@platejs/core` and `@platejs/utils`, you MUST create TWO separate `minor` changeset files, one for each package. DO NOT group them in a single file.
62
+
53
63
**Example (Illustrating multiple files for one package):**
54
64
55
65
File 1: `core-major.md`
@@ -144,29 +154,4 @@ This section explains **what changed for the user** and **how they should adapt*
144
154
```
145
155
`
146
156
147
-
- **New Features / Enhancements (`minor` changeset):**
148
-
149
-
- - Added `useNewHook()` for managing X.
150
-
```ts
151
-
const value = useNewHook(editor);
152
-
```
153
-
- - Added `newOption` to `PluginName` options for Y.
154
-
- - Added `editor.meta.containerTypes`: an array of container node types derived from enabled plugins that have `plugin.node.isContainer = true`.
155
-
- - Updated `editor.api.fragment` to automatically use `editor.meta.containerTypes` as a default for the `containerTypes` option when not explicitly provided.
156
-
157
-
- **Bug Fixes (`patch` changeset):**
158
-
159
-
- - Fixed an issue where typing at the end of a link would not extend the link mark.
160
-
- - Corrected the behavior of `someFunction()` to prevent crashes with empty inputs.
161
-
162
-
- **Removals (Always `major`):**
163
-
- - Removed `obsoleteFunction()` from `**PackageName**`. There is no direct replacement.
164
-
- - Removed default shortcuts for `**SomePlugin**`. Configure them via `editor.configure(SomePlugin, { shortcuts: { ... } })` if needed.
165
-
166
-
**Writing Style:**
167
-
168
-
- **Clarity and Precision:** Be unambiguous.
169
-
- **Action-Oriented:** Use past tense verbs to describe changes. Use imperative mood for migration steps (e.g., "- Replace...", "- Update...").
170
-
- **User-Focused:** Prioritize information crucial for developers integrating the changes.
171
-
172
-
By strictly following these guidelines, we will maintain a high-quality, accurate, and developer-friendly changelog where each change is distinctly categorized.
- Follow the Changeset Guide (.claude/commands/changeset.md) for structure, naming, and writing style
99
93
- For registry changes, update docs/components/changelog.mdx
100
94
95
+
**Critical Requirement: Separate Changesets**
96
+
- You MUST create a separate changeset file for EACH package AND EACH change type (major, minor, patch).
97
+
- A single changeset file MUST contain only ONE package in its frontmatter.
98
+
- **Example 1:** If a PR adds a `minor` feature to `@platejs/core` and a `patch` fix to `@platejs/utils`, you MUST create TWO files: one for `@platejs/core` (minor) and one for `@platejs/utils` (patch).
99
+
- **Example 2:** If a PR adds `minor` features to both `@platejs/core` and `@platejs/utils`, you MUST create TWO separate `minor` changeset files, one for each package.
100
+
- This is essential for correct semantic versioning. DO NOT group multiple packages in one file.
101
+
101
102
**Changeset Standards (for package changes):**
102
103
- Use descriptive file naming: `[package]-[change-type].md`
103
104
- Include proper YAML frontmatter with affected packages and change types
@@ -132,4 +133,8 @@ jobs:
132
133
- One file per distinct change to enable proper SemVer bumping
133
134
- Update changelog.mdx for registry component changes
134
135
136
+
**Changeset required when updating packages**
137
+
- Updating `docs/components/changelog.mdx` is required when updating `apps/www/src/registry`
138
+
- Use `/docs` command to update documentation
139
+
135
140
Please analyze the changes in this PR and create appropriate changeset files and/or update the changelog following the guide.
0 commit comments