<?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 Sachin Jat on Medium]]></title>
        <description><![CDATA[Stories by Sachin Jat on Medium]]></description>
        <link>https://medium.com/@sachin.jat?source=rss-eba785eefc98------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*18U-SpFuYyLGoA0f</url>
            <title>Stories by Sachin Jat on Medium</title>
            <link>https://medium.com/@sachin.jat?source=rss-eba785eefc98------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 30 Nov 2026 14:53:24 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@sachin.jat/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[How to Use Replit and try out different languages]]></title>
            <link>https://medium.com/virtoustack-softwares/how-to-use-replit-and-try-out-different-languages-4c2f2bda6036?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/4c2f2bda6036</guid>
            <category><![CDATA[replit]]></category>
            <category><![CDATA[repl]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Thu, 30 Jun 2022 05:58:18 GMT</pubDate>
            <atom:updated>2022-06-30T05:58:18.353Z</atom:updated>
            <content:encoded><![CDATA[<p><a href="https://replit.com/">Replit</a> is a popular free online IDE that you can use to create your projects with very little setup. This editor supports over almost all languages.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KbdlMTZPVJQ2PK2MUjs6Rg.png" /></figure><h3>How to create a free Replit account</h3><p>To get started, you will first need to go to the <a href="https://replit.com/">Replit homepage</a>. In the top right hand corner, click on <a href="https://replit.com/signup?from=landing">Sign Up</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*nYay7mKSNg4rZco6KYNiMw.png" /></figure><p>You can create an account with your own username, email, and password. Or you can create an account using your Google, Facebook, or GitHub account.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/577/1*GDgHcscFPzItZp1t0I8TrQ.png" /></figure><p>Once you are logged in, then it should take you to your account homepage.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5SdG58HXWWjd5sjBoZ2MKQ.png" /></figure><h3>What is a Repl and how do you create one?</h3><p>Repl stands for read-eval-print loop and it is an interactive programming environment for developers to create small projects.</p><p>In Replit, there are three places where you can create a new repl.</p><p>One way is to click on the Create Repl button located at the top left hand corner of the homepage.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/261/1*ZisouZY9FD5vdcCX1rFgFg.png" /></figure><p>You can also create a repl by clicking on the + icon under the Create section.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/538/1*9tGiSTKDi6PftNnVFItGUg.png" /></figure><p>The last option is the click on the + icon located at the upper right hand corner.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/361/1*ATN1YjenC8NpbpRWRruyEw.png" /></figure><p>Then you can choose from one of Replit’s many templates including Python, Node, Java, dart, typescript, and more.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*yLhEQJHWkV_xRh7dG7AITg.png" /></figure><p>Once you choose your language, pick a name for your project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/552/1*5hJ8eDGXIB8isXw2bsxhhA.png" /></figure><p>For the free version of Replit, you are not allowed to create private projects. If you want a private repl, then you will need to upgrade to the paid subscription.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/238/1*jMe31DLmhQl8IP1ZatBGnw.png" /></figure><p>Once you are done naming your repl, click on the blue Create Repl button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/245/1*dk5ACaUkp5vgjZwVcO_U0Q.png" /></figure><p>Then you should be taken to the editor.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LFd2ih66-EnWE9A4R2WU4w.png" /></figure><h3>Basic features of the Replit editor</h3><p>In this section, I will go over some of the basic features you can use in the Replit editor. These features include a debugger, files and folders, version control, unit tests, and more.</p><h3>Replit Files and Folders</h3><p>In the upper left hand corner, you can click on the file icon to add files and folders to your project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/586/1*oKlnU_4SkDJY1AkCIrLtWw.png" /></figure><p>To add a file, click on the Add file icon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/313/1*XNbVsvhhnvrht3J7tR2b3g.png" /></figure><p>To add a folder, click on the Add folder icon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/298/1*-0JpXrbIM3DJTiAw_nx2aw.png" /></figure><p>If you want to upload files or folders from your computer, click on the three vertical dots icon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/264/1*3CrOHuDJunjSwUjHOUpdsg.png" /></figure><p>If you need to delete files or folders, then click on the three dots icon located next to the file you want to delete. Then from there, choose the delete option.</p><p>You can also right click on the file and you should see the list of options.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/229/1*-2yETjzHFOd7x0UN6HUgWw.png" /></figure><h3>Version control in Replit</h3><p>You also have the ability to connect to your GitHub account and create a repository for this project. At the time of this writing, this feature is currently in beta.</p><p>First click on the version control icon on the left hand side of the editor page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/286/1*BomBvNM6g7hTc2qTB-Xjew.png" /></figure><p>You will be prompted to grant Replit permission to create new repositories on GitHub.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/300/1*26V_o-XIavChx8TlCWdJRQ.png" /></figure><p>Now all of our changes will be tracked and we can push those changes to GitHub. Write a short commit message and click on the Commit &amp; push button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/238/1*QdWlh3geLZxNKcgThwtVyQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/271/1*zdBlUliIwbM6qznmWo8K7w.png" /></figure><p>You should see all of your commit messages in the version control panel.</p><h3>How to install packages in Replit</h3><p>You can also install different packages into your projects like http, image picker and more using the Packages(depends on sdk ) panel on the left hand side of the editor page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/540/1*-JNaw_00L2BAnQKp-0CzWw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/524/1*6c3PBjIhbX6GBYlvLESYrQ.png" /></figure><p>Search for the package that you want to use and click on the + icon to install it into your project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/482/1*a7UcaSqc57fDPxB1j7Ay-g.png" /></figure><p>Inside the console, which is located on the right hand side of the screen, you should see the package being installed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/494/1*yO6Ob7ZQzUwf0pViu29ZCQ.png" /></figure><h3>Secrets (Environment variables) in Replit</h3><p>you will have to use the Secrets tab to store your environment variables. You can find this Secrets icon on the left hand side of the editor page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/512/1*aYF7ZGHVZNVP4TCE-ZcsdQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/437/1*IdpvZ8JHM5Lay8p1wFnnRA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/350/1*31hSnnT1oCf4C4oVMFdUkw.png" /></figure><p>If you need to edit that variable, hover your mouse over the variable name and click on the pencil icon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/241/1*KpAlKXZ0bOjxbdV3nlBliA.png" /></figure><p>Now you should be able to use that environment variable inside your code.</p><h3>How to customize Replit settings</h3><p>If you need to customize the editor settings for your project, click on the settings icon on the left hand side of the editor page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/846/1*jb8U47bOqem6v3nB_-2Olw.png" /></figure><h3>Replit Database</h3><p>If you want to use Replit’s key-value storage, then click on the Database icon on the left hand side of the editor page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/211/1*GKSQ5GMHFlPTtw_ppPXwtQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/307/1*NyGkosj5zJaRIbrGaMhe0g.png" /></figure><p>To learn more about how to use the Replit Database, please visit the <a href="https://docs.replit.com/hosting/database-faq">documentation</a>.</p><h3>How to add unit tests in Replit</h3><p>If you need to add Unit tests to your project, click on the Unit tests icon on the left hand side of the editor page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/555/1*e1sp4vKOZCDWKPt55PTj1w.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4c2f2bda6036" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/how-to-use-replit-and-try-out-different-languages-4c2f2bda6036">How to Use Replit and try out different languages</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Configuring Typescript Linting with eslint]]></title>
            <link>https://medium.com/virtoustack-softwares/configuring-typescript-linting-with-eslint-e340c4d9807e?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/e340c4d9807e</guid>
            <category><![CDATA[eslint]]></category>
            <category><![CDATA[typescript]]></category>
            <category><![CDATA[linter]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Wed, 29 Jun 2022 06:14:52 GMT</pubDate>
            <atom:updated>2022-06-29T10:19:07.744Z</atom:updated>
            <content:encoded><![CDATA[<p>Linting is <strong>the automated checking of your source code for programmatic and stylistic errors</strong>. This is done by using a lint tool (otherwise known as linter). A lint tool is a basic static code analyzer. The term linting originally comes from a Unix utility for C</p><p>ESLint is a tool for <strong>identifying and reporting on patterns found in ECMAScript/JavaScript/TypeScript code</strong>, with the goal of making code more consistent and avoiding bugs. In many ways, it is similar to TSLint and TSHint with a few exceptions: ESLint uses Espree for TypeScript parsing.</p><p>Now you can configure TypeScript linting for the project. First, we install eslint using npm:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/386/1*lcvQuZGcHVivu4hfjFB0Qg.png" /></figure><p>Then, run eslint’s initialization command to interactively set up the project:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/259/1*tbUHl1fElalQTVMTNHKjMQ.png" /></figure><p>Then ,select the options</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/501/1*WgoCqAfwlIqEfqpn8U9Z2Q.png" /></figure><p>answer all questions according to your need:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yrSJ73sqN5COgXbQZgi1vQ.png" /></figure><p>here is our .eslintrc.json file</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/792/1*nPpwfD6VBRCXJz3htyPgcg.png" /></figure><p>Run the linter to check all files with the .ts TypeScript extension:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/330/1*qIEDIRCr8lwB5n_uGa2p-A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/749/1*eY3SeJSp7_v1jQaccEcgPA.png" /></figure><p>to fix comman lint errors we can use eslint fix:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/247/1*UqKMRkPYVjvrMMF26nhvCw.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e340c4d9807e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/configuring-typescript-linting-with-eslint-e340c4d9807e">Configuring Typescript Linting with eslint</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Set Up a Node.js Project with TypeScript]]></title>
            <link>https://medium.com/virtoustack-softwares/how-to-set-up-a-node-js-project-with-typescript-b96bc21cf978?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/b96bc21cf978</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[typescript]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Wed, 29 Jun 2022 05:45:09 GMT</pubDate>
            <atom:updated>2022-06-29T05:45:09.191Z</atom:updated>
            <content:encoded><![CDATA[<h3>Step 1 — Initializing the Project</h3><p>Now, we need to create the project <em>folder:</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/191/1*q9OJ3bPmGt37P9plhtiOsA.png" /></figure><p>Then cd into that project folder:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/149/1*QUmHi4-NvQOn8rrIctAQVQ.png" /></figure><p>Now we’re ready to initialize a node package:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/704/1*dlcfS7f9rJLkvxKMpObmCA.png" /></figure><p>Once you’ve reached the last step it will say:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/207/1*bTS151YZF0jA2qXxKBHAQw.png" /></figure><p>Hit enter and you’ll see your new package.json file that should look something like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/203/1*-XWPMuyuHpc8roTZNmY06Q.png" /></figure><h3>Step 2 — Configuring the TypeScript Compiler</h3><p>Now that your npm project is initialized, you are ready to install and set up TypeScript.</p><p>Run the following command from inside your project directory to install the TypeScript:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/413/1*mIseiBsSjwPbnvluVQBQcQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/329/1*HHeZKI5eWwKbj1sgghhnfg.png" /></figure><p>TypeScript uses a file called tsconfig.json to configure the compiler options for a project. Create a tsconfig.json file in the root of the project directory:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/283/1*9F2OtsQTkGz170o6rV0ObQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/231/1*ksg70cxWmX8DXK_HbojWMw.png" /></figure><p>Then paste in the following JSON:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/344/1*oiENosepRmO5x_C6s_AxgQ.png" /></figure><p>Let’s go over some of the keys in the JSON snippet above:</p><ul><li>module: Specifies the module code generation method. Node uses commonjs.</li><li>target: Specifies the output language level.</li><li>moduleResolution: This helps the compiler figure out what an import refers to. The value node mimics the Node module resolution mechanism.</li><li>outDir: This is the location to output .js files after transpilation. In this tutorial you will save it as dist.</li></ul><h3>Step 3 — Create TypeScript Express Server</h3><p>Now, it is time to install the <a href="https://expressjs.com/">Express</a> framework and create a server:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/424/1*hM5KEf-oFBNAzwJ6-ID1Dg.png" /></figure><p>for types support:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/421/1*BtRRiObMX4YElNXp1KDkeQ.png" /></figure><p>The above command installs the Express <em>types</em> for TypeScript support. Types in TypeScript are files, normally with an extension of .d.ts. The files are used to provide type information about an API, in this case the Express framework.</p><p>This package is required because TypeScript and Express are independent packages. Without the @types/express package, there is no way for TypeScript to know about the types of Express classes.</p><p>Next, create a src folder in the root of your project directory:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/218/1*oQWKQh_QzVE33eW2SCSB4w.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/188/1*s-6ntRyXUWKhXUGLNZjyjw.png" /></figure><p>Then create a TypeScript file named app.ts within it:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/266/1*nvSJ17R0oW7OKuq3iH-X3A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/403/1*xfnbqmJzXSIOWX9XGZCLEA.png" /></figure><p>now we can write our typescript code in app.ts:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/491/1*uWFYIEIRvjJGXZDtrLh_WA.png" /></figure><p>The code above creates Node Server that listens on the port 3000 for requests. To run the app, you first need to compile it to JavaScript using the following command:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/217/1*kgQPOM7eUsfobgtK9M1zWw.png" /></figure><p>Javascript compiled code</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/671/1*I14tV_0ped7b9B6_6gxA9w.png" /></figure><p>Run the JavaScript output with node:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/252/1*tR-tqQc594HOFa6Am9Pp4Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/589/1*oJYYcVS18jFYIzMCOcLjIw.png" /></figure><p>final code:</p><p><a href="https://replit.com/@sachinjat2802/goon#goon/src/app.ts">https://replit.com/@sachinjat2802/goon#goon/src/app.ts</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b96bc21cf978" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/how-to-set-up-a-node-js-project-with-typescript-b96bc21cf978">How to Set Up a Node.js Project with TypeScript</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Dart basic -1]]></title>
            <link>https://medium.com/virtoustack-softwares/dart-basic-1-8a377ddf2c6c?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/8a377ddf2c6c</guid>
            <category><![CDATA[dart]]></category>
            <category><![CDATA[dart-data-types]]></category>
            <category><![CDATA[dartlang]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Mon, 30 May 2022 12:10:44 GMT</pubDate>
            <atom:updated>2022-06-23T03:43:35.418Z</atom:updated>
            <content:encoded><![CDATA[<h3>what is Dart?</h3><p>Dart is an open-source general-purpose programming language developed by Google. It supports application development in both client and server-side. But it is widely used for the development of android apps, iOS apps, IoT(Internet of Things), and web applications using the Flutter Framework.</p><p>It is meant for both server side as well as the user side.</p><p>The Dart SDK comes with its compiler — the Dart VM and a utility dart2js which is meant for generating Javascript equivalent of a Dart Script so that it can be run on those sites also which don’t support Dart.</p><p>Dart is Object-oriented language and is quite similar to that of Java Programming. Dart is extensively use to create single-page websites and web-applications. Best example of dart application is Gmail.</p><p>my first program with dart</p><p>void main() {<br> print(‘Hello World!’);<br>}</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oO_5Tr21BnGRbzbGl6uRQA.png" /></figure><h3>Dart Comments</h3><p>In every programming language comments play an important role for a better understanding of the code in the future or by any other programmer. Comments are a set of statements that are not meant to be executed by the compiler. They provide proper documentation of the code.</p><p><strong>Types of Dart Comments:</strong></p><ol><li>Dart Single line Comment.</li><li>Dart Multiline Comment.</li><li>Dart Documentation Comment.</li></ol><p><strong>Dart Single line Comment: </strong>Dart single line comment is used to comment a line until line break occurs. It is done using a double forward-slash (//).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/776/1*E8s42wAtOfHEX5jIcH499Q.png" /></figure><p><strong>Dart Multi-Line Comment: </strong>Dart Multiline comment is used to comment out a whole section of code. It uses ‘/*’ and ‘*/’ to start and end a multi-line comment respectively.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/742/1*tFW1vEldiZwjXxB5rJm1Yg.png" /></figure><p><strong>Dart Documentation Comment: </strong>Dart Documentation Comments are a special type of comment used to provide references to packages, software, or projects. Documentation comments “///”(C# Style)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/805/1*hG7OLITlfGWTJNm_yyDN5Q.png" /></figure><h3>Dart Variables</h3><p>A variable name is the name assign to the memory location where the user stores the data and that data can be fetched when required with the help of the variable by calling its variable name. There are various types of variable which are used to store the data. The type which will be used to store data depends upon the type of data to be stored.</p><p><strong>Conditions to write variable name or identifiers :</strong></p><ol><li>Variable name or identifiers can’t be the keyword.</li><li>Variable name or identifiers can contain alphabets and numbers.</li><li>Variable name or identifiers can’t contain spaces and special characters, except the underscore(_) and the dollar($) sign.</li><li>Variable name or identifiers can’t begin with number.</li></ol><h3>Dart Data Types</h3><p>whenever a variable is created, each variable has an associated data type. In Dart language, there is the type of values that can be represented and manipulated in a programming language.</p><p>Dart supports the following built-in Data types.</p><ul><li>Number</li><li>Strings</li><li>Boolean</li><li>Lists</li><li>Maps</li><li>Runes</li><li>Symbols</li></ul><h3>Dart Number</h3><p>The Darts Number is used to store the numeric values. The number can be two types — integer and double.</p><ul><li><strong>Integer </strong>— Integer values represent the whole number or non-fractional values. An integer data type represents the 64-bit non-decimal numbers between -263 to 263. A variable can store an unsigned or signed integer value. The example is given below -</li></ul><p><strong>int</strong> marks = 1;</p><ul><li><strong>Double </strong>— Double value represents the 64-bit of information (double-precision) for floating number or number with the large decimal points. The double keyword is used to declare the double type variable.</li></ul><p><strong>double</strong> pi = 12.23;</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/731/1*OjfmABBJV04KMJHeyomZoQ.png" /></figure><h3>Dart Strings</h3><p>A string is the sequence of the character. If we store the data like — name, address, special character, etc. It is signified by using either single quotes or double quotes. A Dart string is a sequence of UTF-16 code units.</p><ol><li>String msg = “first dart string”;</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/761/1*0_O7QLDvxmw3yuH1FeH74w.png" /></figure><h3>Dart Boolean</h3><p>The Boolean type represents the two values — true and false. The bool keyword uses to denote Boolean Type. The numeric values 1 and 0 cannot be used to represent the true or false value.</p><ol><li>bool isTrue = <strong>true</strong>;</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/713/1*9sG-W3s97VigEQnLYggbYg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/814/1*MSAOsYx0tWH1hdqTNu5OIA.png" /></figure><h3>Dart Lists</h3><p>In Dart, The list is a collection of the ordered objects (value). The concept of list is similar to an array. An array is defined as a collection of the multiple elements in a single variable. The elements in the list are separated by the comma enclosed in the square bracket[]. The sample list is given below.</p><ol><li>List list = [1,2,3]</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/736/1*pQvmB2dPqBv5Dz5CKGuYNQ.png" /></figure><h3>Dart Maps</h3><p>The maps type is used to store values in key-value pairs. Each key is associated with its value. The key and value can be any type. In Map, the key must be unique, but a value can occur multiple times. The Map is defined by using curly braces ({}), and comma separates each pair.</p><ol><li>Map student = {‘name’: ‘sachin’, ‘age’:22, ‘Branch’: ‘Computer Science’}</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/982/1*zW6MpTK3i3V79x--hCW9kg.png" /></figure><h3>Dart Runes</h3><p>As we know that, the strings are the sequence of Unicode UTF-16 code units. Unicode is a technique which is used to describe a unique numeric value for each digit, letter, and symbol. Since Dart Runes are the special string of Unicode UTF-32 units. It is used to represent the special syntax.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/841/1*4llove2BqTyjA3AnKg2foA.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8a377ddf2c6c" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/dart-basic-1-8a377ddf2c6c">Dart basic -1</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Some Important javascript Object methods]]></title>
            <link>https://medium.com/virtoustack-softwares/some-important-javascript-object-methods-81d80c1710c8?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/81d80c1710c8</guid>
            <category><![CDATA[objects]]></category>
            <category><![CDATA[javascript-object]]></category>
            <category><![CDATA[javascript]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Fri, 29 Apr 2022 04:04:07 GMT</pubDate>
            <atom:updated>2022-04-29T04:04:07.193Z</atom:updated>
            <content:encoded><![CDATA[<h3>1.Object.values()</h3><p>The Object.values() method returns an array of a given object&#39;s own enumerable property values</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/974/1*tOi6uyEvL85RFTiPHdieBA.png" /></figure><h3>2.Object.seal()</h3><p>The Object.seal() method seals an object, preventing new properties from being added to it and marking all existing properties as non-configurable. Values of present properties can still be changed as long as they are writable.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/937/1*ujz-VQOBsrTa9jAMi7LWhA.png" /></figure><h3>3.Object.preventExtensions()</h3><p>The Object.preventExtensions() method prevents new properties from ever being added to an object.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/932/1*EoGu1Pnu1RawI0r4PKh2GQ.png" /></figure><h3>4.Object.keys()</h3><p>The Object.keys() method returns an array of a given object&#39;s own enumerable property names, iterated in the same order that a normal loop would.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/894/1*8bsbeWuldR_N5oLPvudUgQ.png" /></figure><h3>5.Object.isSealed()</h3><p>The Object.isSealed() method determines if an object is sealed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/914/1*m2NOkFtWKytwpe84RDE9nA.png" /></figure><h3>6.Object.freeze()</h3><p>The Object.freeze() method freezes an object. A frozen object can no longer be changed; freezing an object prevents new properties from being added to it, existing properties from being removed, prevents changing the enumerability, configurability, or writability of existing properties, and prevents the values of existing properties from being changed. In addition, freezing an object also prevents its prototype from being changed. freeze() returns the same object that was passed in.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/898/1*fa3jKqleZinTqqZvVgIumg.png" /></figure><h3>7.Object.isFrozen()</h3><p>The Object.isFrozen() determines if an object is frozen.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/910/1*XifTv51vZJGzj49WZVtdXA.png" /></figure><h3>8.Object.isExtensible()</h3><p>The Object.isExtensible() method determines if an object is extensible (whether it can have new properties added to it).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/953/1*rjodqibpoJzjdgsgDYlfzw.png" /></figure><h3>9.Object.is()</h3><p>The Object.is() method determines whether two values are the same value.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/886/1*b_iScKK7YThnnTTMJCr0wg.png" /></figure><h3>10.Object.hasOwn()</h3><p>The Object.hasOwn() static method returns true if the specified object has the indicated property as its <em>own</em> property. If the property is inherited, or does not exist, the method returns false.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/882/1*dEsv3Xvof43d8CELGqvAMw.png" /></figure><h3>11.Object.assign()</h3><p>The Object.assign() method copies all enumerable own properties from one or more <em>source objects</em> to a <em>target object</em>. It returns the modified target object.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DvJadAPPpXJtMtE4Qn9Shw.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=81d80c1710c8" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/some-important-javascript-object-methods-81d80c1710c8">Some Important javascript Object methods</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Some Important javascript array methods]]></title>
            <link>https://medium.com/virtoustack-softwares/some-important-javascript-array-methods-2800df18626?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/2800df18626</guid>
            <category><![CDATA[arrays]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[function]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Thu, 28 Apr 2022 11:24:06 GMT</pubDate>
            <atom:updated>2022-04-28T12:44:59.697Z</atom:updated>
            <content:encoded><![CDATA[<h3>1. filter()</h3><p>The filter() method creates a new array with all elements that pass the test implemented by the provided function.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/934/1*NN_5qso0XHbm-Dw8B_D98Q.png" /></figure><h3>2. forEach()</h3><p>The forEach() method executes a provided function once for each array element.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/945/1*gtkfmGVfaIuA59DdudgD2w.png" /></figure><p>forEach() method itself doesn’t return a new array.</p><h3>3. some()</h3><p>The some() method tests whether at least one element in the array passes the test implemented by the provided function. It returns true if, in the array, it finds an element for which the provided function returns true; otherwise it returns false. It doesn&#39;t modify the array.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1011/1*2wTQMMdXfWQWi6_rAQyzGA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/914/1*7KYM68wisMkVKLx_I2SxSA.png" /></figure><h3>4. every()</h3><p>The every() method tests whether all elements in the array pass the test implemented by the provided function. It returns a Boolean value.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/971/1*20Fsi5GWicmVCSrb6SBj1w.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/935/1*u2tKiWAoxvZktdiz8iiVlw.png" /></figure><h3>5. includes()</h3><p>The includes method determines whether an array includes a certain value among its entries, returning true or false as appropriate.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*6BRvfjQ15eCqZeglYy2EZg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/934/1*MwpNpViLPikk_svao5PxUg.png" /></figure><h3>6. map()</h3><p>The map() method creates a new array populated with the results of calling a provided function on every element in the calling array.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/921/1*0w8xSRbISC7fHcGIIpTh5g.png" /></figure><h3>7. reduce()</h3><p>The reduce() method executes a user-supplied &quot;reducer&quot; callback function on each element of the array, in order, passing in the return value from the calculation on the preceding element. The final result of running the reducer across all elements of the array is a single value.</p><p>The first time that the callback is run there is no “return value of the previous calculation”. If supplied, an initial value may be used in its place. Otherwise the array element at index 0 is used as the initial value and iteration starts from the next element (index 1 instead of index 0).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/953/1*5IjcOq9c1R9dKsmuq-L4Tg.png" /><figcaption>Reduce with no initial value</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/932/1*19DmVDzNTJTlYOuzTGST-Q.png" /><figcaption>Reduce with initial value 1</figcaption></figure><h3>8. sort()</h3><p>The sort() method sorts the elements of an array in place and returns the sorted array. The default sort order is ascending, built upon converting the elements into strings, then comparing their sequences of UTF-16 code units values.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/963/1*DyJG36ObxayfdT8gK0FBuw.png" /><figcaption>char sorting of numbers</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/952/1*nQUwG3R_CvXMmbXUcSG86g.png" /><figcaption>descending order sort</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/918/1*iXBqtTC20bwdaqTG-3bSgA.png" /><figcaption>ascending order sort</figcaption></figure><h3>9. find()</h3><p>The find()method returns the first element in the provided array that satisfies the provided testing function. If no values satisfy the testing function, undefined is returned.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/909/1*6nxSqmyu7aBheXmWVgkGcQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/936/1*tbeioDVxGm3xNHh0yY_3sg.png" /></figure><h3>10. findIndex()</h3><p>The findIndex() method returns the index of the first element in the array that satisfies the provided testing function. Otherwise, it returns -1, indicating that no element passed the test.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/915/1*nEyFi0cPdr7a7z52RRkdXQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/912/1*8_tWVtf__sMc72ggm0-KVw.png" /></figure><h3>11.values()</h3><p>The values() method returns a new <em>array iterator</em> object that contains the values for each index in the array.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/910/1*HBgu-1Tt-H6Ew-rf6uyMZg.png" /></figure><h3>12.unshift()</h3><p>The unshift() method adds one or more elements to the beginning of an array and returns the new length of the array.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/917/1*23CmFhwg2PERc-3leQz02w.png" /></figure><h3>13.toString()</h3><p>The toString() method returns a string representing the specified array and its elements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/916/1*yHkHujm5YhuQCEvGbuCoLg.png" /></figure><h3>14.toLocaleString()</h3><p>The toLocaleString() method returns a string representing the elements of the array. The elements are converted to Strings using their toLocaleString() methods and these Strings are separated by a locale-specific String (such as a comma &quot;,&quot;).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yfuv-NO5RHATTy4fm-HZ6Q.png" /></figure><h3>15.splice()</h3><p>The splice() method changes the contents of an array by removing or replacing existing elements and/or adding new elements in place.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/974/1*8cUvxfIkhldIP_5m7ZonQA.png" /><figcaption>adding 11 at 0 index without deleting anything</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/974/1*t9yM2DOpBDhC0bV1Qj0rZQ.png" /><figcaption>adding 12 at index 2 and delete next 3 elements after it</figcaption></figure><h3>15.slice()</h3><p>The slice() method returns a shallow copy of a portion of an array into a new array object selected from Start to End(end not included) where Start and end represent the index of items in that array. The original array will not be modified.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/964/1*q7uUBEERCW4_Z3aQN2QEig.png" /></figure><h3>16.shift()</h3><p>The shift() method removes the first element from an array and returns that removed element. This method changes the length of the array.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1002/1*1TbG4vAo17b01E1M94h7lQ.png" /></figure><h3>17.reverse()</h3><p>The reverse() method reverses an array in place. The first array element becomes the last, and the last array element becomes the first.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/984/1*c7jqAUN1-PuW3qZLe6EJtA.png" /></figure><p>example code:-<a href="https://replit.com/@sachinjat2802/VainSickDehardwarization#index.js">https://replit.com/@sachinjat2802/VainSickDehardwarization#index.js</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2800df18626" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/some-important-javascript-array-methods-2800df18626">Some Important javascript array methods</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Firestore Data into Algolia using Cloud Functions.]]></title>
            <link>https://medium.com/virtoustack-softwares/firestore-data-into-algolia-using-cloud-functions-23460755c92?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/23460755c92</guid>
            <category><![CDATA[firebase-cloud-functions]]></category>
            <category><![CDATA[algolia]]></category>
            <category><![CDATA[firebase]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Thu, 28 Apr 2022 06:58:35 GMT</pubDate>
            <atom:updated>2022-04-28T06:58:35.739Z</atom:updated>
            <content:encoded><![CDATA[<h3>What is Algolia?</h3><p>Algolia is a hosted search engine, offering full-text, numerical, and faceted search, capable of delivering real-time results from the first keystroke. Algolia’s powerful API lets you quickly and seamlessly implement search within your websites and mobile applications. Our search API powers billions of queries for thousands of companies every month, delivering relevant results in under 100ms anywhere in the world.</p><h3>What is Firestore?</h3><p>Firestore is <strong>a NoSQL document database built for automatic scaling, high performance, and ease of application development</strong>. While the Firestore interface has many of the same features as traditional databases, as a NoSQL database it differs from them in the way it describes relationships between data objects.</p><p>1.open a firebase function project</p><p>2. install algoliasearch npm package with the help of below command</p><blockquote><em>npm install algoliasearch</em></blockquote><p>3.set algolia app id , algolia api key ,algolia index name in config file</p><h3>Add a firebase collection to algolia with https functions</h3><p>lets create a function that upload firebase collection to algolia</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/631/1*3a1USs6Bljr6bORZUdGCwA.png" /></figure><p>here we use <em>db</em>.collection(“products”).get() to get data from firestore</p><p>querySnapshot.docs.forEach((<em>doc</em>: { data: () <em>=&gt;</em> <em>any</em>; id: <em>any</em>; }) <em>=&gt;</em> {</p><p><em>const</em> document = <em>doc</em>.data();</p><p>document.objectID = <em>doc</em>.id;</p><p>console.log(<em>doc</em>.data());</p><p><em>const</em> record = document;</p><p>algoliaRecords.push(record);</p><p>});</p><p>we are pushing snapshot data in array and adding firebase doc.id to document so we can create algolia document objectID</p><p><em>collectionIndex</em>.saveObjects(algoliaRecords,</p><p>(<em>_error</em>: <em>any</em>, <em>content</em>: <em>any</em>) <em>=&gt;</em> {</p><p><em>res</em>.status(200)</p><p>.send(“COLLECTION was indexed to Algolia successfully.”);</p><p>});</p><p>here we are saving data to alogia collection index and sending response to https function</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/372/1*rP3FWExp0U9Mz76NCQR0Hw.png" /></figure><p>way to export https functions in firebase functions</p><h3>Adding firebase triggers that will handle create update and delete</h3><p>1 trigger when new product is created</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*K0scUAP2eH8yWySAdLW3YQ.png" /></figure><p>2.trigger when product is deleted</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/368/1*RJ7AdzNz4XvGcltw3d90OQ.png" /></figure><p>3.trigger when product update</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/378/1*dmB3WrIns0ciXGHIB0_m1w.png" /></figure><p>now we have to trigger these function on the bases of change in firestore so we will use cloud trigger functions</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/444/1*WluB9nnNFbBUffM_tgSn9A.png" /></figure><p>This is complete firestore data migration to algolia with cloud functions</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=23460755c92" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/firestore-data-into-algolia-using-cloud-functions-23460755c92">Firestore Data into Algolia using Cloud Functions.</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[how to creainvoice pdf using node js]]></title>
            <link>https://medium.com/virtoustack-softwares/how-to-creainvoice-pdf-using-node-js-93a9888efb12?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/93a9888efb12</guid>
            <category><![CDATA[invoice]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[billing]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Tue, 19 Apr 2022 10:52:42 GMT</pubDate>
            <atom:updated>2022-04-19T10:52:42.881Z</atom:updated>
            <content:encoded><![CDATA[<h3>how to create invoice pdf using node js</h3><p>Many times I find some requirement in my project to generate a invoice generate data into PDF format.</p><p>I am going to explain the easiest way to generate invoice PDF in NodeJS.</p><p>here I am going to use pdf kit to generate pdf</p><h3>Minimum requirements</h3><ol><li>basic of npm modules</li><li>basic Javascript</li></ol><h3>Step1: install express and pdfkit</h3><p>Express.js, or simply Express, is a back end web application framework for Node.js, released as free and open-source software under the MIT License. It is designed for building web applications and APIs. It has been called the de facto standard server framework for Node.js</p><p>Pdfkit :A JavaScript PDF generation library for Node and the browser.</p><p>open terminal in your project and install express and pdfkit as follow:</p><blockquote><em>npm i express pdfkit</em></blockquote><h3>Step 2: import packages inside index.js</h3><p>index. js typically <strong>handles your app startup, routing and other functions of your application and does require other modules to add functionality</strong>.</p><blockquote><em>const express = require(‘express’);<br>const PDFDocument = require(‘pdfkit’);</em></blockquote><p>The Node.js file system module allows you to work with the file system on your computer.so we need to import it also.</p><blockquote><em>const fs = require(‘fs’);</em></blockquote><p>lets create a object of PDFDocument with the help of new operator here we can predefine paper size in which we need invoice like A1,A2,A3 etc..</p><blockquote><em>const doc = new PDFDocument({size: ‘A4’});</em></blockquote><p>lets add some text to pdf with some font-style ,font-size, define location of text in pdf and text size.</p><blockquote><em>doc.font(“EuclidSquare-SemiBold.ttf”).fontSize(18).text(‘TAX INVOICE’,37, 70,<br>{ width: 156,height:30})</em></blockquote><p>=&gt;font-style :EuclidSquare-SemiBold.ttf</p><p>=&gt;font-size:18</p><p>=&gt;content :TAX INVOICE</p><p>=&gt;text pixel position on paper :37,70</p><p>=&gt;width of text 156,height of text 30</p><blockquote><em>doc.fill(“#C0C0C0”, “#C0C0C0”)</em></blockquote><p>here fill is used to fill color in text here I am filling yellow color in document</p><blockquote><em>doc.image(‘logo.png’, 468, 22, {width: 127, height: 127})</em></blockquote><p>doc.image function used to add image in invoice pdf</p><blockquote><em>doc.lineJoin().rect(37, 151, 520, 1)</em></blockquote><p>doc.linejon function create a line rect function creates reactangle with given dimensions .</p><p>for demo <a href="https://replit.com/@sachinjat2802/EnergeticHarmfulWebpage#index.js">https://replit.com/@sachinjat2802/EnergeticHarmfulWebpage#index.js</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=93a9888efb12" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/how-to-creainvoice-pdf-using-node-js-93a9888efb12">how to creainvoice pdf using node js</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Bulk json data upload in Firebase FireStore in spark plan with node js]]></title>
            <link>https://medium.com/virtoustack-softwares/bulk-json-data-upload-in-firebase-firestore-in-spark-plan-with-node-js-3a17746d96b1?source=rss-eba785eefc98------2</link>
            <guid isPermaLink="false">https://medium.com/p/3a17746d96b1</guid>
            <category><![CDATA[bulk-data-collection]]></category>
            <category><![CDATA[firebase]]></category>
            <category><![CDATA[firestore]]></category>
            <dc:creator><![CDATA[Sachin Jat]]></dc:creator>
            <pubDate>Tue, 19 Apr 2022 07:24:54 GMT</pubDate>
            <atom:updated>2022-04-19T07:24:54.259Z</atom:updated>
            <content:encoded><![CDATA[<ol><li>generate new private key for firebase sdk .</li></ol><p>=&gt;go to <a href="https://console.firebase.google.com/">https://console.firebase.google.com</a></p><p>=&gt; than click on Project settings .</p><p>=&gt;than go to service account and download a new private key by clicking on generate new private key.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/749/1*GIS77XNAlRjTJ1AmeQMmXg.png" /></figure><p>2. create a new node project with</p><p>npm init</p><p>3.install firebase-admin with</p><p>npm i firebase-admin</p><p>4. create index.js than import firebase admin as admin</p><p>const admin = require(“firebase-admin”);</p><p>5.import service account json</p><p>9const serviceAccount = require(“./account.json”);</p><p>6. than initializeApp and put service account json</p><p>admin.initializeApp({</p><p>credential: admin.credential.cert(serviceAccount)</p><p>});</p><p>7.create a variable for firestore</p><p>const db = admin.firestore();</p><p>8.import bulk json data</p><p>var bulkData= require(“./data.json”);</p><p>9.function to create collection and upload bulkData</p><p>bulkData.forEach(async function (obj) {</p><p>await db.collection(‘bulkData’).add({</p><p>name: obj.name,</p><p>documentType: obj.documentType,</p><p>dimension: obj.dimension,</p><p>sets: obj.sets,</p><p>assets: obj.assets</p><p>}).then(obj =&gt; console.log(obj.id))</p><p>.catch(err =&gt; console.log(err))</p><p>})</p><ul><li>example code -<a href="https://github.com/sachinjat2802/jsonfirebaseimporter">https://github.com/sachinjat2802/jsonfirebaseimporter</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3a17746d96b1" width="1" height="1" alt=""><hr><p><a href="https://medium.com/virtoustack-softwares/bulk-json-data-upload-in-firebase-firestore-in-spark-plan-with-node-js-3a17746d96b1">Bulk json data upload in Firebase FireStore in spark plan with node js</a> was originally published in <a href="https://medium.com/virtoustack-softwares">VirtouStack</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>