yardz commented on issue #13632:
URL: https://github.com/apache/superset/issues/13632#issuecomment-802063718


   > Redux official [documentation](https://redux.js.org/faq/code-structure) 
has a very nice guide on best practices for code structuring and they also 
recommend using feature folders instead of having all the reducers and actions 
in one place:
   > 
   
   Well, I personally don't like feature folders, It brings up some problems.  
Let's assume that we have three features (`FeatureA`, `FeatureB` and 
`FeatureC`). Now that all of these features are increments of the previous one. 
That is, `FeatureC` is an increment of `FeatureB` and `FeatureB` is an 
increment of  `FeatureC`.
   Sharing code between these features will not be as intuitive as they are in 
folders at different levels.
   
   The division by logical layers seems to me to be more stable, easier to 
maintain and easier to understand. Pages are pages, no matter what features are 
inside that page. For example, `FeatureA` is one page, `FeatureB` would add a 
new area on this page, and `FeatureC` would add a button in this new area.
   In this case, we would have a structure like this:
   ```
   - pages/
     - PageB
     - PageC
     - PageFeatureA/
        index.tsx
        - components/
           area-a.tsx
           area-b.tsx
           area-FeatureB.tsx
           btn-FeatureC.tsx
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to