I changed my back-end routes to start with /api so the React front end could talk to the server. I also updated the book routes so they returned data the UI actually needed, like the author’s name instead of just the author ID. I added support for query parameters so filtering and searching could be done cleanly from the front end. If I could go back to HW1, I would design the API responses with the UI in mind from the beginning, especially for things like joins and filtering.
I mostly used server-side validation and only relied on the front end for basic user feedback. Server-side validation is safer because it cannot be bypassed and keeps the database protected. The downside is that users only see errors after submitting a form. Client side validation gives faster feedback and feels better to use, but it adds more code and still cannot replace what server-side checks.
My experience with React was mostly positive. I liked how state controls the UI and how it helps organize the code. I struggled most with managing state between components, especially getting the table to refresh after adding a book.
With plain JavaScript code, you have to manually update elements, which becomes messy as the app grows. React lets you describe what the UI should look like based on state, and it updates automatically. I prefer React because it scales better and keeps the UI cleaner.
Types helped catch mistakes like using the wrong fields from API responses. They were sometimes annoying to write, especially with Axios and props, but they did helped prevent bugs. Overall, they were more helpful than frustrating.
I did use LLMs but only to fill in code that I was going to write. For example, when I have something in mind to type down, and the LLMs suggested the same thing, I would just use the suggestion. In these cases, LLMs can be useful since it does speed up my progress.
Overall, I still think the LLMs are not very accurate. I think their code suggestions are often wrong compared to right, so it does slow down development if I were to use them consistently. I did not use them much during this assignment so I don't think it affected what I learned from this assignment.