Open M123-dev opened 2 years ago
I agree with the suggestions, though not sure if we would separate widgets by features or just keep them separate in the widgets folder. To me keeping widgets separately makes more appealing and easy then making them separate by functionality
lib/widgets
and lib/generic_lib
, would be better to club them all in one widgets
folder and maybe make further subdirectories thereon.lib/helpers/analytics
pages
directory, it is too much clutter there, would be better to do some cleanup there as well.lib
lib/network
Still thinking much before i make further suggestions, Till then waiting for everyone else's suggestions
I don't say that the files are always in the good folders (I don't even have an opinion on that), but I read somewhere about a deadline on May 23rd and now I have limited time to devote to Smoothie. In short: to me, that's not a priority at all.
Hi @M123-dev, I also think that there is a need to re-structure the project. I also have some suggestions regarding the structure e.g.
I'll share a detailed structure soon. I think @AshAman999 did a good job with folder structure and I also believe that we should wait for others suggestions.
This has gotten a bit stale, understandably, there were many other things with higher priority. However, I think that it is still quite a big problem, I personally have trouble finding my way around the folders, instead I always search for the class names and find my way around, but for new contributors I imagine it to be much more difficult.
It's not a big refactoring per se, it's moving around files and fixing imports, the bigger part is finding a suitable system,
Here is an example of my suggestion (according to this article, it's called feature-first):
The main point being, if I want to change something in the lists, I can work in the list's folder, why search together all the needed files in different folders if we can combine them.
Problem
Somehow Smoothie's project structure has become very confusing lately.
CategoryCache
andOrderedNutrientsCache
are underpages/product/
pages/product
some incard/.../
(also some product related ones there)lib/widgets
andlib/generic_lib
for widgets and a lot of widgets are just spread across other foldersProposed solution
Looking at all the files we currently have I propose a separation by features with some exceptions. Meaning that we split all the Pages including theire specific widgets into theire own folders e.g scan, product_page, user_managment ... But I would keep a dedicated lib/widgets folder for common widgets like SmoothCard etc and keep the database folder (you could even see it as a own feature)
I'd like to hear your opinions on that @monsieurtanuki @g123k @cli1005 @AshAman999 @bhattabhi013 @vik4114 @teolemon