Skip to content

Commit 37c2abe

Browse files
authored
Replace migration-template.md with breaking-change-template.md (#2931)
1 parent 9f5618e commit 37c2abe

File tree

2 files changed

+123
-3
lines changed

2 files changed

+123
-3
lines changed

agents/templates/INDEX.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,6 @@ This non-docs index lists the canonical authoring templates for CMS documentatio
2222
- Purpose: Lightweight API page skeleton covering endpoints, auth, parameters, and example requests/responses.
2323
- Path: `agents/templates/api-template.md`
2424

25-
## Migration Template
26-
- Purpose: Migration/breakingchange format with impact, before/after, and a numbered migration sequence.
27-
- Path: `agents/templates/migration-template.md`
25+
## Breaking Change Template
26+
- Purpose: Individual breaking change page with BreakingChangeIdCard, side-by-side v4/v5 comparison, and migration notes with manual procedure.
27+
- Path: `agents/templates/breaking-change-template.md`
Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
---
2+
title: TITLE — Clear statement of the change
3+
description: One sentence explaining what changed and who is affected.
4+
sidebar_label: Short label (optional)
5+
displayed_sidebar: cmsSidebar
6+
tags:
7+
- breaking changes
8+
- TOPIC_TAG
9+
- upgrade to Strapi 5
10+
---
11+
12+
<!--
13+
================================================================================
14+
BREAKING CHANGE TEMPLATE
15+
================================================================================
16+
Use this template for individual breaking change pages in /cms/migration/vX-to-vY/breaking-changes/
17+
18+
QUICK REFERENCE - BreakingChangeIdCard props:
19+
plugins → Add if this breaking change affects plugin developers
20+
codemod → Add if FULLY handled by a codemod
21+
codemodPartly → Add if PARTLY handled by a codemod
22+
codemodName="..." → Codemod identifier (e.g., "entity-service-document-service")
23+
codemodLink="..." → GitHub URL to the codemod source code
24+
info="..." → Additional note (e.g., "handled by data migration script")
25+
26+
EXAMPLES:
27+
<BreakingChangeIdCard /> → No plugins, no codemod
28+
<BreakingChangeIdCard plugins /> → Affects plugins, no codemod
29+
<BreakingChangeIdCard plugins codemod /> → Affects plugins, fully automated
30+
<BreakingChangeIdCard plugins codemodPartly → Affects plugins, partly automated
31+
codemodName="my-codemod"
32+
codemodLink="https://github.com/strapi/strapi/blob/develop/..." />
33+
================================================================================
34+
-->
35+
36+
import Intro from '/docs/snippets/breaking-change-page-intro.md'
37+
import MigrationIntro from '/docs/snippets/breaking-change-page-migration-intro.md'
38+
39+
# TITLE — Can expand on frontmatter title
40+
41+
Brief 1-2 sentence introduction explaining the change in context.
42+
43+
<Intro />
44+
45+
<BreakingChangeIdCard />
46+
47+
## Breaking change description
48+
49+
<SideBySideContainer>
50+
51+
<SideBySideColumn>
52+
53+
**In Strapi v4**
54+
55+
Description of v4 behavior.
56+
57+
```js
58+
// v4 code example (if applicable)
59+
```
60+
61+
</SideBySideColumn>
62+
63+
<SideBySideColumn>
64+
65+
**In Strapi 5**
66+
67+
Description of v5 behavior.
68+
69+
```js
70+
// v5 code example (if applicable)
71+
```
72+
73+
</SideBySideColumn>
74+
75+
</SideBySideContainer>
76+
77+
## Migration
78+
79+
<MigrationIntro />
80+
81+
### Notes
82+
83+
- Key information about the change.
84+
- Link to related documentation: see [Feature name](/cms/path/to/doc).
85+
- Link to related breaking change: see [related entry](/cms/migration/v4-to-v5/breaking-changes/slug).
86+
87+
### Manual procedure
88+
89+
Describe manual steps if needed. Use one of these formats:
90+
91+
**Simple prose:** No manual migration is required.
92+
93+
**Numbered steps:**
94+
1. First action
95+
2. Second action
96+
3. Verify the change
97+
98+
**Before/After code:**
99+
100+
<SideBySideContainer>
101+
<SideBySideColumn>
102+
103+
**In Strapi v4**
104+
105+
```js
106+
// Old code
107+
```
108+
109+
</SideBySideColumn>
110+
111+
<SideBySideColumn>
112+
113+
**In Strapi 5**
114+
115+
```js
116+
// New code
117+
```
118+
119+
</SideBySideColumn>
120+
</SideBySideContainer>

0 commit comments

Comments
 (0)