<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Pooja K Vishnoi on Medium]]></title>
        <description><![CDATA[Stories by Pooja K Vishnoi on Medium]]></description>
        <link>https://medium.com/@pooja.k.vishnoi?source=rss-ef02704abc82------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*XUWSnAVdYbBGjHcnevzXoQ.jpeg</url>
            <title>Stories by Pooja K Vishnoi on Medium</title>
            <link>https://medium.com/@pooja.k.vishnoi?source=rss-ef02704abc82------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 27 Nov 2026 13:23:35 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@pooja.k.vishnoi/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Basic understanding of Webpack]]></title>
            <link>https://medium.com/@pooja.k.vishnoi/basic-understanding-of-webpack-f9abab00be4f?source=rss-ef02704abc82------2</link>
            <guid isPermaLink="false">https://medium.com/p/f9abab00be4f</guid>
            <dc:creator><![CDATA[Pooja K Vishnoi]]></dc:creator>
            <pubDate>Sun, 28 Aug 2022 06:33:39 GMT</pubDate>
            <atom:updated>2022-09-05T06:02:34.833Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3CNj0xge35TkBCHUR5-eNQ.jpeg" /></figure><h4><strong>What is Webpack and why do we need webpack?</strong></h4><p>Webpack is static module bundler for modern JavaScript Application. So basically webpack takes all the js files, css files, assests like images and bundle them, which can be understood by the browser. It does this by internally building Dependency tree from one or more entry points and it includes all the modules that we have imported in our code and makes their bundle. It’s easy to load a single file rather than loading all the files including all the modules that are used in the program code(The code that a developer writes).Webpack is a JavaScript program by node and it runs on build time.</p><h4><strong>Little Overview of Browsers:</strong></h4><p>Browers not only run JavaScript but also HTML and CSS. The main function of a web browser is to present the web resource that we choose by requesting it from the server and displaying it. So HTML and CSS is used for the skeleton and the designing part and JavaScript for the interactivity. Browsers have their JavaScript engine, which runs the Js code. JavaScript is evolving day-by-day like it gets out with something cool everyday. What happens is the ECMAScript is evolving continously but the browsers are not. So to implement a new feature given by ECMAScript it’ll take time for Browser’s developer. If we want our website to run on almost all the browsers, webpack comes handy. Browsers like Chrome, Edge, Firefox, Internet Explorer, Opera and many more, each have a it’s market share. Chrome is on the top with 69.28%, then Edge, Firefox, etc with 7 and less percent. So what webpack does is it make sure that if the browser market is greater than 0.25% and is not dead then the website can run on that browser.</p><h4>What webpack actually does?</h4><p>Webpack comes in place when we have to give a final packaged website.</p><ol><li>Packaging: It puts all the code together. Removes all the spaces. Adds CSS and CSS-in-JS.</li><li>Transpilation: It transpiles TypeScript to JavaScript ES5 and Babel ES6 to JavaScript ES5 which all the browsers can understand.</li><li>Automatic Dependency Tree Management.</li></ol><p><strong><em>Webpack is extremely powerful with the concepts of loaders and plugin.That I will make another blog for it. To understand webpack deeply do read:</em></strong></p><p><a href="https://webpack.js.org/concepts/">https://webpack.js.org/concepts/</a></p><p><a href="https://webpack.js.org/">The Official Documentation</a></p><p><strong><em>Thank you for reading.</em></strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f9abab00be4f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Event loop]]></title>
            <link>https://medium.com/@pooja.k.vishnoi/event-loop-3fb235d387ac?source=rss-ef02704abc82------2</link>
            <guid isPermaLink="false">https://medium.com/p/3fb235d387ac</guid>
            <category><![CDATA[javascript]]></category>
            <dc:creator><![CDATA[Pooja K Vishnoi]]></dc:creator>
            <pubDate>Fri, 14 Jan 2022 07:22:30 GMT</pubDate>
            <atom:updated>2022-01-14T09:25:17.745Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ila21_5iCiFRENSAVfk8nw.png" /></figure><h3>What is javaScript?</h3><p>JavaScript is basically a single threaded programming language. JavaScript allows to implement complex features in web pages.JavaScript is an Interpreted language which means the code runs from top to bottom and the result of the code is immediately returned.</p><h3>So what is a single threaded programming language?</h3><p>I.e JavaScript can run only one piece of code at a time. This also means that JavaScript has one Call Stack.</p><h3>Now what is Call Stack??</h3><p>Call Stack is a data structure which records where are we in the program. If we invoke a function, we put that on stack. when a function returns a value, it gets popped off the top of the stack.</p><h3>What makes our website slow?</h3><p>When things which are slow are on the stack, it slows down the website. This is called Blocking. For example, the method such as console.log is not slow, network requests, image processing are something which causes blocking. Since, JavaScript is a single threaded programming language, this means that we have to wait till the request is completed. So till then, what does the website do? Basically nothing, it has to wait till the request is completed. Here comes *WebAPIs* to rescue.</p><h3>What is WebAPI?</h3><p>WebAPIs are some features that is provided by the browser and not the JavaScript engine. It includes setTimeout, DOM API, HTTP requests and so on.This helps in creating non-blocking, responsive behaviour.</p><h3>What is an event loop?</h3><p>First, we have to understand what happens when a code run. Whenever a function is called it first goes in the Call Stack and it stays there until it returns something, for ex, if a function returns a setTimeout function then it is handled by WebAPI without blocking the main thread.The callback function that is in the setTimeout runs as long as for the time we passed in the second arguement. Once it is completed, It does not goes in back in the Call Stack rather it goes in something we call Task Queue. Now comes event loop in picture. Event loop check whether the Call Stack is empty, if yes, then the callback is added to the Call Stack gets invoked and returns a value and get popped off.</p><p><strong><em>Hope it was not confusing.Thank you for reading.</em></strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3fb235d387ac" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>