Northeastern-Electric-Racing / PM-Dashboard-v2

Northeastern Electric Racing Project Management Dashboard - version 2
https://nerpm.netlify.app
GNU Affero General Public License v3.0
15 stars 2 forks source link

#729 home adjustments #742

Closed jamescd18 closed 2 years ago

jamescd18 commented 2 years ago

Changes

Okay so basically I did all the adjustments that I wanted to do from my last PR and some more cuz cleanup is good whatever lol. Turns out I could get rid of the useEffect hook refetch if I just had a flexible object for query parameters instead of function parameters. I expended the work package endpoint to have enough query parameters to replace the separate upcoming deadlines endpoint so that's good. Also had to ensure that query params were included in query keys or else it would use the same resulting data for both instances of the same hook no matter the input. Good to know react-query is smart.

Test Cases

improved testing by testing the url function for work package query parameters urls

Screenshots (if applicable)

Now that's a proper home page

Screen Shot 2022-06-19 at 8 26 33 AM

Checklist

It can be helpful to check the Checks and Files changed tabs. Please review the contributor guide and reach out to your squad if anything is unclear. Please request reviewers and ping on slack only after you've gone through this whole checklist.

Closes #729