Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mick: individual project week 1-2 #374

Open
5 of 6 tasks
MickDellaert opened this issue May 20, 2022 · 0 comments
Open
5 of 6 tasks

Mick: individual project week 1-2 #374

MickDellaert opened this issue May 20, 2022 · 0 comments

Comments

@MickDellaert
Copy link

MickDellaert commented May 20, 2022

Week 1-2

Repos:

Must haves:

  • user can see all channels
  • user can add new channel
  • user can see other users( user can see who send the message)
  • user can see a message with a time stamp
  • user can send a message
  • user can set its user name

Check-In

I Need Help With:

  • Thinking in the 'React way': managing state.
  • Planning in general: as usual I had an idea on how to build the app, but didn't really make a plan. I tend to just go ahead and face the issues when they present themselves. With my current level of experience I also don't have a clear idea of the challenges ahead of the project.
  • I tried to separate the code into components and use a container pattern, trying to make components reusable as well. Doing this I had to do quite some prop drilling and used a composition with props.children for a few components to resolve this. I'm not sure if this a clean way of doing things because logic becomes nested and sometimes hard to track.

What went well?

  • In general it went well and it's very nice to work with React when you get the hang of it (a bit). By this I mean working with state and useEffect and to see how the app really becomes 'reactive'.
  • I tried to make many commits, still could make more small ones.
  • This was the first time I worked with branches on a personal project, which was very useful.

What went less well?

  • I got stuck often trying to grab the state, for example making a POST request and immediately setting the state with a .then. The state doesn't get set immediately and this led to some hacky ways trying to resolve this. I also should look into async some more.
  • I tried to fetch only a few times, but ended up needing more fetches with different calls in several places, still tried to limit it though.

Lessons Learned

  • Still need to work on keeping things organized. Try to plan ahead a bit more and not go at it in an 'impulsive manner'. Less trial and error. Less hackiness. Read some more documentation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant