Learn Nest.js By Creating A REST API. Nest.js Is A Node.js Framework For Building Server Side Applications.The reason why i like nest.js is because the code is organized a lot in diffrent modules, controllers and services
Why Use GraphQL GraphQL is used to build API’s, It’s like REST, But the reason why to use GraphQL instead of REST is because in graphql you can just give the data and what user need is upto him/her Example Let’s just take a example of a simple REST vs GraphQL API We have a REST endpoint that return array of posts from database, Not A Real Endpoint https://api.programmingfire.com/posts/ Output:
Why Docker ? Docker allows you to package an application with its environment and all of its dependencies into a “box”, called a container. Usually, a container consists of an application running in a stripped-to-basics version of a Linux operating system. An image is the blueprint for a container, a container is a running instance of an image. Create a Sample Node.js App (Optional) In your terminal run: # NPM npm init # YARN yarn init Then, create a server.
Step 1 - Download And Install Node.js Download Node.js From NodeSource Let’s download nodejs from Nodesource. NodeSource is a company which provides enterprise-grade Node support and maintains a repository containing the latest versions of Node.js. curl -sL https://deb.nodesource.com/setup_14.x | sudo -E bash - Install Node.js From Debian Repository Let’s install nodejs now: sudo apt-get install nodejs -y Check The Version Of Node.js node --version Check The Version Of NPM npm --version Step 2 (Optional) - Create A Sample Node.