<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Md. Mizanur Rahaman</title>
    <description>The latest articles on DEV Community by Md. Mizanur Rahaman (@mizanur919).</description>
    <link>https://dev.to/mizanur919</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F777525%2Fa26934a7-4335-42ee-be6e-8b54881b0d9b.jpeg</url>
      <title>DEV Community: Md. Mizanur Rahaman</title>
      <link>https://dev.to/mizanur919</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mizanur919"/>
    <language>en</language>
    <item>
      <title>Make salary calculator using Chat GPT and Excel</title>
      <dc:creator>Md. Mizanur Rahaman</dc:creator>
      <pubDate>Sat, 29 Apr 2023 16:40:36 +0000</pubDate>
      <link>https://dev.to/mizanur919/make-salary-calculator-using-chat-gpt-and-excel-4jeb</link>
      <guid>https://dev.to/mizanur919/make-salary-calculator-using-chat-gpt-and-excel-4jeb</guid>
      <description>&lt;p&gt;In this blog post, we will explore how to make a salary calculator using Chat GPT and Excel. A salary calculator is a tool that can help employees or employers determine their net income after taxes and deductions. With the help of Chat GPT, we can create an interactive and user-friendly salary calculator that can be used by anyone with basic Excel skills.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--ln6gOseJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/r4o7yty944vqyw6k8fuo.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--ln6gOseJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/r4o7yty944vqyw6k8fuo.jpg" alt="Image description" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The first step in making a salary calculator using Chat GPT and Excel is to gather the necessary information. We need to know the employee's gross salary, any pre-tax deductions, and their tax filing status. Once we have this information, we can create a formula in Excel that calculates the employee's net income after taxes and deductions.&lt;/p&gt;

&lt;p&gt;Next, we can integrate Chat GPT into Excel using the Power Automate platform. Power Automate allows us to create a chatbot that can interact with users and provide them with personalized results. We can create a chatbot that prompts users for the necessary information and then uses the Excel formula to calculate their net income.&lt;/p&gt;

&lt;h2&gt;
  
  
  Here the full video tutorial:
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://youtu.be/ab0OWqaLZCo"&gt;https://youtu.be/ab0OWqaLZCo&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Finally, we can test and refine our salary calculator to ensure that it is accurate and user-friendly. We can use feedback from users to make improvements and adjustments to the chatbot and formula.&lt;/p&gt;

&lt;p&gt;With the help of Chat GPT and Excel, we can create a powerful and interactive salary calculator that can help employees and employers make informed decisions about their finances. To see an example of how to create a salary calculator using Chat GPT and Excel, check out the YouTube video linked above.&lt;/p&gt;

</description>
      <category>chatgpt</category>
      <category>javascript</category>
      <category>html</category>
      <category>css</category>
    </item>
    <item>
      <title>Uses of JSON.parse() and JSON.stringify()</title>
      <dc:creator>Md. Mizanur Rahaman</dc:creator>
      <pubDate>Thu, 26 May 2022 04:54:42 +0000</pubDate>
      <link>https://dev.to/mizanur919/uses-of-jsonparse-and-jsonstringify-2c17</link>
      <guid>https://dev.to/mizanur919/uses-of-jsonparse-and-jsonstringify-2c17</guid>
      <description>&lt;p&gt;Sometimes we confused that when I have to use JSON.parse() and when JSON.stringify. But most of the time we have to use both of these. &lt;/p&gt;

&lt;p&gt;Let's talk about these important topics-&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;JSON.parse()&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
JSON.parse() takes JSON string and transform it into JavaScript object.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Input&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;let userStringData = '{"name":"Hamid","email":"hamid@gmail.com","profession":"Doctor"}';

let userObjData = JSON.parse(userStringData);

console.log(userObjData);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Output&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{ name: 'Hamid', email: 'hamid@gmail.com', profession: 'Doctor' }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;&lt;u&gt;JSON.stringify()&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
JSON.stringify() is total oposite of JSON.parse(). Where JSON.stringify takes JavaScript object and transform it into JSON string.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;Input&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;let userObjectData = 
{ name: 'Hamid', email: 'hamid@gmail.com', profession: 'Doctor' }

let userJSONData = JSON.stringify(userObjectData);

console.log(userJSONData);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;&lt;u&gt;Output&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{"name":"Hamid","email":"hamid@gmail.com","profession":"Doctor"}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Follow me on &lt;a href="https://www.linkedin.com/in/dev-mizanur919/"&gt;LinkedIn&lt;/a&gt;&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>json</category>
      <category>webdev</category>
    </item>
    <item>
      <title>CRUD app with Node, Express, and MongoDB</title>
      <dc:creator>Md. Mizanur Rahaman</dc:creator>
      <pubDate>Fri, 24 Dec 2021 16:42:31 +0000</pubDate>
      <link>https://dev.to/mizanur919/crud-app-with-node-express-and-mongodb-22af</link>
      <guid>https://dev.to/mizanur919/crud-app-with-node-express-and-mongodb-22af</guid>
      <description>&lt;p&gt;Let’s clear about some technical words that are used here-&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CRUD:&lt;/strong&gt; CRUD stands for Create, Read, Update and Delete. Here-&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;C - Create (Post)&lt;/li&gt;
&lt;li&gt;R - Read (Get)&lt;/li&gt;
&lt;li&gt;U - Update (Put)&lt;/li&gt;
&lt;li&gt;&lt;p&gt;D - Delete (Delete)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Express: Express is a framework to communicate with NodeJS with Database.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;MongoDB: This is a database where we can store our data.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Node JS: Node.js is an open-source, cross-platform back-end JavaScript runtime environment that uses the V8 engine to execute JavaScript code outside of the web browser.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The whole process of these technologies at a glance in an image.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--h3Z39khm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tsqa1dvfomjr1fau9t0u.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--h3Z39khm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tsqa1dvfomjr1fau9t0u.png" alt="node js crud" width="874" height="322"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Before starting our CRUD operation using these technologies we must install all required packages-&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;NodeJS - From this link, &lt;a href="https://nodejs.org/en/download/"&gt;https://nodejs.org/en/download/&lt;/a&gt; download the LTS version and install it.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;MongoDB - “npm i mongodb” using this command line without double quote can install MongoDB.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Express JS: “npm install express --save” using this command line we can install Express JS.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Cors: “npm i cors” use this command line&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Now Back To The Code&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const express = require("express");
const app = express();
const port = process.env.PORT || 5000;
require('dotenv').config();
const { MongoClient } = require('mongodb');
const ObjectId = require('mongodb').ObjectId;
const cors = require('cors');
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These codes are used as links with the packages.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.use(cors());
app.use(express.json());

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This middleware is for connecting with clients and servers.&lt;br&gt;
&lt;strong&gt;Database configuration with MongoDB&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const uri = `mongodb+srv://${process.env.DB_USER}:${process.env.DB_PASS}@cluster0.4b6iz.mongodb.net/myFirstDatabase?retryWrites=true&amp;amp;w=majority`;
console.log(uri);
const client = new MongoClient(uri, { useNewUrlParser: true, useUnifiedTopology: true });

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Before connecting with the Database must create a .env file to store secret data&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;C - Create (POST) from CRUD&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.post('/order/add', async (req, res) =&amp;gt; {
                const cursor = req.body;
            const result = await orderCollection.insertOne(cursor);
                res.json(result);        
});
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here app.post indicates that this method creates a new record in the database.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;R - Read (GET) from CRUD&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.get('/order', async (req, res) =&amp;gt; {
            const cursor = orderCollection.find({});
            const result = await cursor.toArray();
            res.send(result);
        })

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here app.get indicates that this method reads all orders from the database.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;U - Update (PUT) from CRUD&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app.put('/', (req, res) =&amp;gt; {
        res.send("PUT Request Called")
})
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here app.put indicates that this method updates a record from the database.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;D - Delete (DELETE) from CRUD&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; app.delete('/order/:id', async (req, res) =&amp;gt; {
            const id = req.params.id;
            const query = { _id: ObjectId(id) };
            const result = await orderCollection.deleteOne(query);
            res.json(result);
        });
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here app.delete indicates that this method deletes a record from the database.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>All About Virtual Dom and Context API</title>
      <dc:creator>Md. Mizanur Rahaman</dc:creator>
      <pubDate>Wed, 22 Dec 2021 17:57:39 +0000</pubDate>
      <link>https://dev.to/mizanur919/all-about-virtual-dom-and-context-api-56kd</link>
      <guid>https://dev.to/mizanur919/all-about-virtual-dom-and-context-api-56kd</guid>
      <description>&lt;h2&gt;
  
  
  Virtual Dom
&lt;/h2&gt;

&lt;p&gt;In React, the virtual DOM (Document Object Model) is a programming concept in which a library like ReactDOM keeps an ideal, or "virtual," version of a user interface in memory and syncs it with the "actual" DOM. This is referred to as reconciliation.&lt;br&gt;
Every virtual DOM object is modified when you render a JSX element. After the virtual DOM has been changed, React compares it to a virtual DOM snapshot obtained before the modification.&lt;/p&gt;

&lt;p&gt;React detects which virtual DOM objects have changed by comparing the new virtual DOM to a version previous to the update. This process is called "diffing."&lt;br&gt;
Once React has recognized which virtual DOM objects have changed, it updates the actual DOM with only those objects. React will rebuild your single checked-off list item in our previous example while leaving the rest of your list alone.&lt;/p&gt;

&lt;h2&gt;
  
  
  Context API
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;What is Context API&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;With React v.16.3, the new React Context API allows us to transfer data through our component trees, allowing our components to communicate and exchange data at different levels. We'll look at avoiding prop drilling using React Context in this tutorial. First, we'll define prop drilling and why we should avoid it.&lt;br&gt;
React context API: How it works?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How Context API works?&lt;/strong&gt;&lt;br&gt;
React.createContext() all you need to know must. It will provide you with a customer and a provider. The provider is a component that supplies the state to its children, as its name indicates. It will contain the "store" and serve as the parent of any components that may require it. A component that consumes and utilizes the state is known as a consumer.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Important CSS Properties Must Know</title>
      <dc:creator>Md. Mizanur Rahaman</dc:creator>
      <pubDate>Wed, 22 Dec 2021 03:39:00 +0000</pubDate>
      <link>https://dev.to/mizanur919/important-css-properties-must-know-2le3</link>
      <guid>https://dev.to/mizanur919/important-css-properties-must-know-2le3</guid>
      <description>&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fccdugtx1pycpwh0mlt62.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fccdugtx1pycpwh0mlt62.jpg" alt="Important CSS Properties Must Know"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Flexbox
&lt;/h2&gt;

&lt;p&gt;The main purpose of flexbox is to manage space, distribute space properly to show in a dynamic way. The flexbox is also known as flex layout. This is also used to align content in a container. &lt;/p&gt;

&lt;p&gt;The main part of using flexbox is the best way to proper use of space. Where it will help to respond with devices sizes.&lt;/p&gt;

&lt;p&gt;Before using flexbox we must have a clear concept about flexbox and its all properties.&lt;/p&gt;

&lt;p&gt;There are two things available in flexbox which are-&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Flex container&lt;/li&gt;
&lt;li&gt;Flex items&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;To active flex functionality for inside items, we must use display: flex CSS property.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fulmukag2zr8k63i6yj18.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fulmukag2zr8k63i6yj18.png" alt="css flex"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  CSS Variable
&lt;/h2&gt;

&lt;p&gt;CSS variable looks like other programming language variables. We can use CSS variables to make our style more dynamic and effective. We can set a color or font size or any other styles using CSS variables that will help us to change anytime with a few clicks. It actually used to set global style. Where one change affects all styles.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl0zz9fleui988pmpeegy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl0zz9fleui988pmpeegy.png" alt="CSS Variable"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Pseudo Elements
&lt;/h2&gt;

&lt;p&gt;Pseudo-elements are used to provide extra functionality or affect to an element. In short, we can say that A CSS pseudo-element is used to style specified parts of an element.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Where we can use these Pseudo Elements:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;To style the first letter of the word, first-line, or a specific word of a paragraph or title.&lt;/li&gt;
&lt;li&gt;To set extra words of text before or after a word or a sentence.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;.info-bar::before {
  content: url(smiley.gif);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Image Sprites
&lt;/h2&gt;

&lt;p&gt;Image Sprites is a collection of images where lots of images are put into a single image.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why we should use Image Sprites&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;To reduce load time in a website.&lt;/li&gt;
&lt;li&gt;To get all images in a single image
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;#something {
  left: 0px;
  width: 46px;
  background: url('img_navsprites.gif') 0 0;
}

#prev {
  left: 63px;
  width: 43px;
  background: url('img_navsprites.gif') -47px 0;
}

#next {
  left: 129px;
  width: 43px;
  background: url('img_navsprites.gif') -91px 0;
}

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  CSS Box Model
&lt;/h2&gt;

&lt;p&gt;While there is a question about design and layout the Box Model comes up. This is like a wrapper of HTML elements. CSS Box Model consists of Margin, Border, Padding, and Content.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;A short explanation of different parts:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Content:&lt;/strong&gt; Where text, images, videos appear.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Padding:&lt;/strong&gt; It creates some spaces around the content.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Border:&lt;/strong&gt; Border takes parts around the padding. &lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Margin:&lt;/strong&gt; It is also like padding. Which takes some spaces outside the border.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt; div &amp;gt;
&amp;lt; p &amp;gt;This is something&amp;lt; /p &amp;gt;
&amp;lt; /div &amp;gt;

div {
  width: 300px;
  border: 15px solid green;
  padding: 50px;
  margin: 20px;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>css</category>
      <category>style</category>
      <category>boxmodel</category>
      <category>html</category>
    </item>
    <item>
      <title>What is an Rest API, the main purpose of API, GET, POST method</title>
      <dc:creator>Md. Mizanur Rahaman</dc:creator>
      <pubDate>Tue, 21 Dec 2021 18:12:05 +0000</pubDate>
      <link>https://dev.to/mizanur919/what-is-an-api-the-main-purpose-of-api-get-post-method-332k</link>
      <guid>https://dev.to/mizanur919/what-is-an-api-the-main-purpose-of-api-get-post-method-332k</guid>
      <description>&lt;h2&gt;
  
  
  What is an API?
&lt;/h2&gt;

&lt;p&gt;API stands for Application Programming Interface. &lt;strong&gt;It’s like an engine under the hood.&lt;/strong&gt; It works behind the scene like a ghost. It helps us to add, delete, update or get all data using this API. &lt;/p&gt;

&lt;p&gt;In short, users send a request to API that what do want to do? Then the API responds to the user’s requests. &lt;/p&gt;

&lt;p&gt;Let’s explain with an example-&lt;br&gt;
API like a waiter in a restaurant. Someone is waiting to place an order to the waiter from the menu. &lt;/p&gt;

&lt;p&gt;Then the waiter goes to the kitchen and tells the chafe about the order. Now chafe the dish according to the order. After making the food waiter will carry the food to the customer. &lt;/p&gt;

&lt;p&gt;This whole process like an API works.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Qrtv8PSm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8bpilwkd7i5o8qe7xp2t.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Qrtv8PSm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/8bpilwkd7i5o8qe7xp2t.png" alt="what is an API" width="880" height="258"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Purpose of API
&lt;/h2&gt;

&lt;p&gt;The main purpose of API is to connect clients with databases. This is like a middleman or connector. Where it helps both sides to connect with each other. &lt;br&gt;
API gets a request from the client or user and collects data from the database as required by the client. Then it will deliver or respond to the client.&lt;/p&gt;

&lt;h2&gt;
  
  
  Uses of Get
&lt;/h2&gt;

&lt;p&gt;Get is a method that helps us to get or fetch all data from the server a client or user requested for. &lt;br&gt;
In short Get method loads data from the server as client requests.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;app.get('/order', async (req, res) =&amp;gt; {&lt;br&gt;
                const cursor = orderCollection.find({});&lt;br&gt;
                const result = await cursor.toArray();&lt;br&gt;
                res.send(result);&lt;br&gt;
            })&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Here, all order data loads from the server requested by the client.&lt;/p&gt;

&lt;h2&gt;
  
  
  Uses of Post
&lt;/h2&gt;

&lt;p&gt;This is also related to the server. Using the POST method we can send data to the server from the client-side. &lt;br&gt;
In short, using POST we can send data to a server to create a resource.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;app.post('/order/add', async (req, res) =&amp;gt; {&lt;br&gt;
             const cursor = req.body;&lt;br&gt;
                const result = await orderCollection.insertOne(cursor);&lt;br&gt;
                res.json(result);&lt;br&gt;
            });&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;In this example, a user sends a new record using the POST method, which will be stored in the database.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>react</category>
      <category>reactnative</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
