<?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: Mohit Kala</title>
    <description>The latest articles on DEV Community by Mohit Kala (@mohitkalajain).</description>
    <link>https://dev.to/mohitkalajain</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%2F812464%2F27525dfb-ebfd-4f98-a2af-3d31f7097892.jpg</url>
      <title>DEV Community: Mohit Kala</title>
      <link>https://dev.to/mohitkalajain</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mohitkalajain"/>
    <language>en</language>
    <item>
      <title>React Introduction</title>
      <dc:creator>Mohit Kala</dc:creator>
      <pubDate>Tue, 10 May 2022 14:29:59 +0000</pubDate>
      <link>https://dev.to/mohitkalajain/react-introduction-24ji</link>
      <guid>https://dev.to/mohitkalajain/react-introduction-24ji</guid>
      <description>&lt;p&gt;&lt;strong&gt;What is React&lt;/strong&gt;&lt;br&gt;
React is a free and open-source front-end JavaScript library for building user interfaces based on UI components. It is maintained by Meta and a community of individual developers and companies.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Example&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;import React from "react";

const Example= () =&amp;gt; {
  return (
    &amp;lt;div className="hello_react"&amp;gt;
      &amp;lt;h1&amp;gt; Hello, world this is React ! &amp;lt;/h1&amp;gt;
    &amp;lt;/div&amp;gt;
  );
};

export default Example;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The Example function is a React component that displays the famous introductory ''Hello, world this is React".&lt;/p&gt;

&lt;p&gt;When displayed in a web browser, the result will be a rendering of:&lt;/p&gt;


&lt;h1&gt;Hello, world this is React !&lt;/h1&gt;

&lt;p&gt;&lt;strong&gt;2) React History&lt;/strong&gt;&lt;br&gt;
a) React was Created by Jordan Walke, a software Engineer at Facebook&lt;/p&gt;

&lt;p&gt;b) On April 2017, Facebook announced React Fiber, a new core algorithm of React Library for Building User Interfaces.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3) React Benefits and Features&lt;/strong&gt;&lt;br&gt;
&lt;strong&gt;A) Virtual DOM:&lt;/strong&gt; The virtual DOM (VDOM) is a programming concept where an ideal, or “virtual”, representation of a UI is kept in memory and synced with the “real” DOM by a library such as React DOM. This process is called reconciliation.&lt;/p&gt;

&lt;p&gt;Virtual DOM has the same properties that of the Real DOM, but it lacks the power to directly change the content of the screen.&lt;/p&gt;

&lt;p&gt;Think of Virtual DOM as the blueprint of a machine, changes made to the blueprint doesn’t reflects on the machine itself.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;B) Components&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;React component is the building block of a React application. Let us learn how to create a new React component and the features .&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;i) Functional Components&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Function components are declared with a function that then returns some JSX.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
const Example= () =&amp;gt; &amp;lt;div&amp;gt;Hello, world this is React !&amp;lt;/div&amp;gt;;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;ii) Class-based Components&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Class-based components are declared using ES6 classes.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;class ParentComponent extends React.Component {
  state = { color: 'black' };
  render() {
    return (
      &amp;lt;ChildComponent color={this.state.color} /&amp;gt;
    );
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;C) JSX&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;React JSX is an extension to JavaScript. It enables developer to create virtual DOM using XML syntax. It compiles down to pure JavaScript. Since it compiles to JavaScript, it can be used inside any valid JavaScript code. For example, below codes are perfectly valid.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;class Example extends React.Component {
  render() {
    return (
      &amp;lt;div&amp;gt;
        &amp;lt;p&amp;gt;Example 1&amp;lt;/p&amp;gt;
        &amp;lt;p&amp;gt;React Js&amp;lt;/p&amp;gt;
      &amp;lt;/div&amp;gt;
    );
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;D) One Way Data Binding:&lt;/strong&gt; ReactJS uses one-way data binding. In one-way data binding one of the following conditions can be followed:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;i) Component to View:&lt;/strong&gt; Any change in component data would get reflected in the view.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ii) View to Component&lt;/strong&gt;: Any change in View would get reflected in the component’s data.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;E) Performance:&lt;/strong&gt; React uses virtual DOM and updates only the modified parts. So , this makes the DOM to run faster. DOM executes in memory so we can create separate components which makes the DOM run faster.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;F) Extension:&lt;/strong&gt; React has many extensions that we can use to create full-fledged UI applications. It supports mobile app development and provides server-side rendering. React is extended with Flux, Redux, React Native, etc. which helps us to create good-looking UI.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Useful Git commands for common tasks</title>
      <dc:creator>Mohit Kala</dc:creator>
      <pubDate>Tue, 10 May 2022 14:27:26 +0000</pubDate>
      <link>https://dev.to/mohitkalajain/useful-git-commands-for-common-tasks-21md</link>
      <guid>https://dev.to/mohitkalajain/useful-git-commands-for-common-tasks-21md</guid>
      <description>&lt;p&gt;&lt;strong&gt;1)Git Clone&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Git Clone Is A Command For Downloading Existing Source Code From A Git Repository (Like Azure DevOps, GitHub)&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;git clone “repository url” -b “branch name”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2) Git Branch&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Branches Are Highly Important In The Git World. By Using It, Developers Are Able To Work In Parallel On The Same Project.&lt;/p&gt;

&lt;p&gt;i) Creating A New Branch:&lt;br&gt;
&lt;strong&gt;git branch “branch-name”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;ii) To Push The New Branch&lt;br&gt;
&lt;strong&gt;git push -u “remote” “branch-name”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;iii) Viewing Branches:&lt;br&gt;
&lt;strong&gt;git branch or git branch — list&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;iv) Deleting Branch&lt;br&gt;
&lt;strong&gt;git branch -d “branch name”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3) Git Commit&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Most-Used Command Of Git. Once We Reach A Certain Point In Development, We Want To Save Our Changes (Maybe After A Specific Task Or Issue).&lt;br&gt;
&lt;strong&gt;git commit -m “commit message”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4) Git Push&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;After Committing Your Changes, The Next Thing You Want To Do Is Send Your Changes To The Remote Server. Git Push Uploads Your Commits To The Remote Repository.&lt;br&gt;
&lt;strong&gt;git push “remote” “branch-name”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5) Git Status&lt;/strong&gt;&lt;br&gt;
The Git Status Command Gives Us All The Necessary Information About The Current Branch.&lt;br&gt;
&lt;strong&gt;git status&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;6) Git Diff&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You can use this command to see the unstaged changes on the current branch.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;git diff — staged&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;7) Git Add&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This is the command you need to use to stage changed files. You can stage individual files&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;git add “file path”&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;for all files&lt;br&gt;
**&lt;br&gt;
git add**&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
