Skip to content

Commit 2ab46de

Browse files
committed
Add deprecation guide and info about layout
1 parent 55dc957 commit 2ab46de

File tree

1 file changed

+69
-0
lines changed

1 file changed

+69
-0
lines changed

text/0995-deprecate-non-colocated-components.md

+69
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,9 @@ Or using `component-structure=nested`
113113
index.hbs
114114
```
115115

116+
Note, however, that classi components _importing_ the `layout` and setting it on an `@ember/component` will still work.
117+
The key thing being deprecated is the runtime resolution of templates, so if there is an import involved, there is no runtime resolution.
118+
116119
### `ember-source`
117120

118121
The blueprint for components will need to remove the `classic` option:
@@ -161,6 +164,72 @@ Specifically, we'll remove:
161164

162165
Guides and docs already don't mention the above old layouts.
163166

167+
### How to migrate off old layouts
168+
169+
#### component templates in `templates/components`
170+
171+
**Before**
172+
```
173+
{app,addon}
174+
components/
175+
demo.js
176+
templates/
177+
components/
178+
demo.hbs
179+
```
180+
181+
**After**
182+
```
183+
{app,addon}
184+
components/
185+
demo.js
186+
demo.hbs
187+
```
188+
189+
**After (gjs)**
190+
```
191+
{app,addon}
192+
components/
193+
demo.gjs
194+
```
195+
196+
#### Pods
197+
198+
199+
**Before**
200+
```
201+
{app,addon}
202+
components/
203+
demo/
204+
component.js
205+
template.hbs
206+
```
207+
208+
**After**
209+
```
210+
{app,addon}
211+
components/
212+
demo/
213+
index.js
214+
index.hbs
215+
```
216+
217+
**After (non-nested)**
218+
```
219+
{app,addon}
220+
components/
221+
demo.js
222+
demo.hbs
223+
```
224+
225+
**After (gjs)**
226+
```
227+
{app,addon}
228+
components/
229+
demo.gjs
230+
```
231+
232+
164233
## Drawbacks
165234

166235
If upgrading to ember v6 without any changes,

0 commit comments

Comments
 (0)