ashatat / e-commerce

Basic e-commerce website to practice our gitflow, teamwork, communication and clean code best practices.
MIT License
3 stars 1 forks source link

Agree to the best file structure to go with for components. #34

Closed FarahZaqout closed 6 years ago

FarahZaqout commented 6 years ago

Should be over by the end of tomorrow.

FarahZaqout commented 6 years ago

My Proposed Structure:

My Reasoning:

RamyAlshurafa commented 6 years ago

I recommend this Link https://reactjs.org/docs/faq-structure.html

ashatat commented 6 years ago

If you’re just starting a project, don’t spend more than five minutes on choosing a file structure. Check this link

I think of having two main folders like this:

- components
  |__ // here goes the components that we don't call it in the router
- Pages
  |__// here goes the pages components which we will call it at the router
amusameh commented 6 years ago

I would go with the first method on Ramy's link Are we going to use redux?

ashatat commented 6 years ago

I agree with what @FarahZaqout said, but I am not sure about separating to stateless and stateful is a good idea what do you think guys?

@amusameh , my opinion is to use redux, but only when we need it ((when the state get complicated))

FarahZaqout commented 6 years ago

I don't mind the first method that Ramy linked. Keep in mind that when it comes to file structure, it's a matter of what makes most sense to us. I don't think there's right or wrong as long as our separation of concerns is decent.

So let's just vote by using thumbs up and see what makes most sense to us as a team

FarahZaqout commented 6 years ago

Alright, we will be using the first method specified in react docs.