Github Link : https://github.com/firdousalam/Full-Stack-Training/tree/march16class Documents : Service Structure : https://github.com/firdousalam/Full-Stack-Training/tree/march16class/march16 Complete initial Setup Step 1 : create react app using npx create-react-app client step 2 : Setup Nodejs Posts Service a. mkdir posts b. cd posts c. npm init -y d. npm install express cors axios nodemon step 3 : Setup Nodejs Comments Service a. mkdir Comments b. cd Comments c. npm init -y d. npm install express cors axios nodemon as per above for post service we need two URL one to save post and one to retrieve post Let’s Create the following Path In our Posts Service Go to Posts Service create One File (Index.js) and initial Express code GoTo package.json file script : nodemon index.js Let Us Implement Comments Service so here we will try to add comments based on postId i.e one post may contain multiple comments
Github Link : https://github.com/firdousalam/Full-Stack-Training/tree/march16class Documents : Service Structure : https://github.com/firdousalam/Full-Stack-Training/tree/march16class/march16 Complete initial Setup Step 1 : create react app using npx create-react-app client step 2 : Setup Nodejs Posts Service a. mkdir posts b. cd posts c. npm init -y d. npm install express cors axios nodemon step 3 : Setup Nodejs Comments Service a. mkdir Comments b. cd Comments c. npm init -y d. npm install express cors axios nodemon as per above for post service we need two URL one to save post and one to retrieve post Let’s Create the following Path In our Posts Service Go to Posts Service create One File (Index.js) and initial Express code GoTo package.json file script : nodemon index.js Let Us Implement Comments Service so here we will try to add comments based on postId i.e one post may contain multiple comments