Feature-based structures tend to work better than technical layers in most cases, especially for larger projects. The reason is simple: when you need to touch a feature, all the relevant files are in one place instead of scattered across different "components" and "services" folders. So instead of having `/src/components/UserCard`, `/src/services/userService`, `/src/utils/userHelpers`, you bundle everything together under `/src/features/user/`. That makes navigation easier and reduces cognitive load while coding. Especially when multiple people are working on a project, you get fewer conflicts and confusion about "where should this actually go?".
Within your features, you can then build a consistent internal structure. Something like `/features/user/components`, `/features/user/hooks`, `/features/user/types`, `/features/user/utils` makes sense - here you have clear subcategories, but everything belongs together thematically. For really large modules, it's worth subdividing further into subfeatures. A practical example: your `/features/user` could be split into `/features/user/authentication`, `/features/user/profile`, `/features/user/settings`.
Things that span multiple features - shared utilities, global types, core services - you put in separate folders like `/shared`, `/lib`, or `/core`. That's really the exception, not the rule. The most important thing is actually just picking a structure and sticking with it consistently. What works best depends on the size and stack of your project, but feature-first is pretty much the standard in practice these days.