File tree Expand file tree Collapse file tree 1 file changed +1
-34
lines changed Expand file tree Collapse file tree 1 file changed +1
-34
lines changed Original file line number Diff line number Diff line change @@ -264,37 +264,4 @@ type UpdateUser = Partial<Pick<User, "name" | "email">>;
264264## Import/Export Patterns
265265
266266- Prefer named exports over default exports
267- - Use barrel exports (index.ts files) for grouping related exports like images or components
268- - Follow generally accepted import ordering conventions
269-
270- Example barrel export:
271-
272- ``` ts
273- import home from " @/assets/icons/home.png" ;
274- import search from " @/assets/icons/search.png" ;
275- import person from " @/assets/icons/person.png" ;
276- import logo from " @/assets/icons/logo.png" ;
277- import save from " @/assets/icons/save.png" ;
278- import star from " @/assets/icons/star.png" ;
279- import play from " @/assets/icons/play.png" ;
280- import arrow from " @/assets/icons/arrow.png" ;
281-
282- export const icons = {
283- home ,
284- search ,
285- person ,
286- logo ,
287- save ,
288- star ,
289- play ,
290- arrow ,
291- };
292- ```
293-
294- Example import usage:
295-
296- ``` ts
297- import { icons } from ' @/constants/icons'
298- //
299- < img src = {icons.home } / >
300- ```
267+ - Follow generally accepted import ordering conventions
You can’t perform that action at this time.
0 commit comments