<?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 Kavinda-chirath on Medium]]></title>
        <description><![CDATA[Stories by Kavinda-chirath on Medium]]></description>
        <link>https://medium.com/@kavindachirath17?source=rss-2aa8757d27f4------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*vdEMP4HkiinoN-ReG74hAQ.jpeg</url>
            <title>Stories by Kavinda-chirath on Medium</title>
            <link>https://medium.com/@kavindachirath17?source=rss-2aa8757d27f4------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 23 Nov 2026 15:45:39 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@kavindachirath17/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[TypeScript Part-2 (Chapter-5)]]></title>
            <link>https://medium.com/@kavindachirath17/typescript-part-2-chapter-5-f2827fcae377?source=rss-2aa8757d27f4------2</link>
            <guid isPermaLink="false">https://medium.com/p/f2827fcae377</guid>
            <category><![CDATA[part-2]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[typescript]]></category>
            <category><![CDATA[angular]]></category>
            <category><![CDATA[chapter-5]]></category>
            <dc:creator><![CDATA[Kavinda-chirath]]></dc:creator>
            <pubDate>Fri, 05 Jun 2026 12:40:27 GMT</pubDate>
            <atom:updated>2026-06-05T12:40:27.770Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_eMW9VmkIk9F3i-mr40G_Q.png" /><figcaption>this is AI generated image</figcaption></figure><ul><li><strong>“let”-</strong> (<strong>Block-Scoped) </strong>If you declare a variable using “<strong>let</strong>” keyword inside a block (like an “if” statement), it cannot be accessed outside of that block.</li><li><strong>var</strong> — <strong>(Function-Scoped / globally scoped):</strong> A variable declared with <strong>“var”</strong> inside a block can still be accessed outside of it.</li></ul><pre>if (true) {<br>  let x: string = &quot;abc&quot;;<br>  var y: number = 23;<br>}<br>// console.log(x); // ERROR: Cannot find name &quot;x&quot;<br>console.log(y);    // Output: 23 (y is accessible)</pre><ul><li><strong>const- </strong>Once a value is assigned to a const variable, it cannot be reassigned. it means When you have a value that should never change, you should use the <strong>“const”</strong> keyword.</li><li><strong>Enums (Enumerations) = </strong>Enums allow you to define a set of named constants, making your code more readable and easier to manage, especially when dealing with a specific set of related values</li></ul><pre>enum Color {<br>  Red = &quot;RED&quot;,<br>  Blue = &quot;BLUE&quot;<br>}<br>console.log(Color.Red); // Output: RED</pre><ul><li><strong>Aliases = </strong>The <strong>“aliase”</strong> is a powerful feature in TypeScript used to give a new name to an existing type or to define complex custom types. (Can be Assigned new name instead of existing data types)</li></ul><pre>type StrData = string; // Using StrData instead of string type</pre><p><strong>Union Types:</strong> You can use aliases to allow a variable to accept multiple types using the pipe ( | ) operator.</p><pre>type ID = number | string;      // type either numer or string<br><br>let num1: ID = 123;    // Valid<br>num1 = &quot;ABC123&quot;;      // Also Valid<br><br>console.log(num1) // ABC123</pre><ul><li>Can be Used for <strong>Complex Structures</strong></li></ul><pre>type User ={<br>  neme: string,<br>  age: number,<br>  isAdmin: boolean<br>}<br><br>let adminUser: User={<br>  neme: &quot;Chamod&quot;,<br>  age: 23,<br>  isAdmin: true<br>}<br><br>console.log(adminUser)</pre><ul><li><strong>Object Types and Intersection Types</strong></li></ul><p>You can use <strong>“type”</strong> to define the shape of an object. Furthermore, you can combine multiple types into a single new type using <strong>Intersection Types</strong> (the “<strong>&amp;</strong>” operator).</p><pre>type HasName = { name: string };<br>type HasAge = { age: number };<br>type HasJob = { jobTitle: string };<br><br>// Intersection Type combining three types<br>type Person = HasName &amp; HasAge &amp; HasJob;<br><br>let person: Person = {<br>  name: &quot;Chamod&quot;,<br>  age: 23,<br>  jobTitle: &quot;Software Engineer&quot;<br>};</pre><ul><li><strong>Can be Used for Define the Structures of Functions</strong></li></ul><p>TypeScript allows you to define the exact signature (parameters and return type) a function should have using type aliases. This ensures consistency when assigning arrow functions to variables.</p><pre>// Define the function signature<br>type Greet = (name: string) =&gt; string;<br><br>// Implement the function<br>let greetUser: Greet = (name: string) =&gt; {<br>  return `Hello ${name}`;<br>};<br><br>console.log(greetUser(&quot;Chamod&quot;)); // Output: Hello Chamod</pre><ul><li><strong>undefined:</strong> When you declare a variable but do not assign a value to it, its default type and value are undefined.</li><li><strong>Double Equals (==):</strong> This is the loose equality operator. It check whether only <strong>values</strong> are equal, but it does <strong>not</strong> check the <strong>types</strong></li><li><strong>Triple Equals (===):</strong> This is the strict equality operator. It checks if both the <strong>values and the types</strong> are identical.</li></ul><h4><strong>Working with Interfaces</strong></h4><p><strong>Extending Interfaces:</strong> You can use the <strong>“extends”</strong> keyword to inherit properties from an existing interface and add new ones. This promotes code reusability.</p><pre>interface User {<br>  name: string;<br>  age: number;<br>}<br><br>let user1: User={<br>  name: &quot;Chamod&quot;,<br>  age: 23<br>}<br><br>interface Employee extends User {<br>  jobTitle: string;<br>}<br><br>let emp1: Employee={<br>  name: &quot;Kamal&quot;,<br>  age: 25,<br>  jobTitle: &quot;Software Engineer&quot;<br>}<br><br>console.log(emp1) </pre><p>from this <strong>“extends” </strong>we can use to avoid code repetition, according to this example: <strong>Employee</strong> also have name and age as well as<strong> User</strong>. from “extends” keyword <strong>User</strong> will be “Parent”, so no need to write that code again and again.</p><p><strong>readonly</strong> : we can use this keyword before variable name for avoid the change the value (update )after assigning.</p><pre>interface User {<br>  name: string;<br>  readonly age: number;   // readonly using<br>}<br><br>let user1: User={<br>  name: &quot;Chamod&quot;,<br>  age: 23<br>}<br><br>interface Employee extends User {<br>  jobTitle: string;<br>}<br><br>let emp1: Employee={<br>  name: &quot;Kamal&quot;,<br>  age: 25,<br>  jobTitle: &quot;Software Engineer&quot;<br>}<br><br>emp1.age = 26    // we can&#39;t update the agecause we used &quot;readonly&quot; for age<br>console.log(emp1)</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f2827fcae377" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is TypeScript — part -1 (Chapter 4)]]></title>
            <link>https://medium.com/@kavindachirath17/what-is-typescript-part-1-chapter-4-87e45d0ad208?source=rss-2aa8757d27f4------2</link>
            <guid isPermaLink="false">https://medium.com/p/87e45d0ad208</guid>
            <category><![CDATA[typescript]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[angular]]></category>
            <category><![CDATA[front-end-development]]></category>
            <category><![CDATA[web-development]]></category>
            <dc:creator><![CDATA[Kavinda-chirath]]></dc:creator>
            <pubDate>Wed, 03 Jun 2026 08:49:34 GMT</pubDate>
            <atom:updated>2026-06-03T08:49:34.894Z</atom:updated>
            <content:encoded><![CDATA[<p>TypeScript is a Superset of JavaScript, which added <strong>types.</strong></p><p>It is free and open source high level programming language developed by Microsoft.</p><p><strong>Static Type </strong>— which allows you to declare exactly what kind of data (such as strings, numbers, or objects) your variables and functions should.</p><p>JavaScript can be difficult to understand what types of data are being passed around.</p><p><strong>Static Type</strong> <strong>Checking</strong> — it means checking during the development.</p><pre>// Create Variables in TypeScript<br><br>let message : string = &quot;Hello&quot;;<br>console.log(message);<br><br>let isDisable : boolean = true;<br>console.log(isdisable);</pre><pre>// Create Arrays<br><br>// common methed to creating arrays<br><br>let marks : number[] = [12,34,45]   <br>console.log(marks)<br><br>// Using Array Interface<br><br>let marksArray : Array&lt;number&gt; // declare<br>marksArray = [12,65,89]       // initialize<br>console.log(marksArray) </pre><p>We can Disable the Checks The Types Using “any” Keyword</p><pre>let x : any = &quot;Hello&quot;<br>x = 34<br>console.log(x)</pre><p><strong>Functions</strong></p><pre>function greet(name: string){<br>     return `Hello ${name}!`<br>}<br>console.log (greet(&quot;Chamod&quot;));</pre><p>Objects Passing to Functions</p><pre>interface User{<br>   name : string,<br>   age : number<br>}<br><br>function processUser(user: User){<br>   return `name : ${user.name} , age : ${user.age}`<br>}<br><br>let user1 : User = {<br>   name : &quot;Chamod&quot;,<br>   age : 45<br>}<br><br>console.log(processUser(user1))</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=87e45d0ad208" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Angular Folders and Files Structure (Chapter-3)]]></title>
            <link>https://medium.com/@kavindachirath17/angular-folders-and-files-structure-champer-3-fc58b7d30609?source=rss-2aa8757d27f4------2</link>
            <guid isPermaLink="false">https://medium.com/p/fc58b7d30609</guid>
            <category><![CDATA[files-and-folder-structur]]></category>
            <category><![CDATA[files-and-folders]]></category>
            <category><![CDATA[angular]]></category>
            <dc:creator><![CDATA[Kavinda-chirath]]></dc:creator>
            <pubDate>Mon, 25 May 2026 16:12:19 GMT</pubDate>
            <atom:updated>2026-05-25T16:14:03.305Z</atom:updated>
            <content:encoded><![CDATA[<p>When you create a new Angular 18 project using the “<strong>ng new&quot;</strong> command, Angular generates a complete workspace with a specific folder and file structure. To a beginner, this can look overwhelming. In this guide, we will break down what each folder and file does, so you can confidently navigate your new Angular application.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/325/1*MnRIoY31Ay9_79p69SjDrg.png" /></figure><h3>1. The Root Folders</h3><ul><li><strong>node_modules/</strong>: This folder contains all the third-party libraries and dependencies required by your Angular project (installed via npm). It is a massive folder, and you should <strong>never</strong> modify the files inside it manually. <em>(Note: This folder is ignored in Git by default).</em></li><li><strong>.vscode/</strong> (Optional): If you are using VS Code, this folder might appear containing workspace-specific settings and recommended extensions.</li><li><strong>public/</strong> (or src/assets/): In newer versions like Angular 18, the public folder is used to store static assets like images, fonts, and the favicon.ico. These files are served directly to the browser.</li></ul><h3>2. The src/ (Source) Folder</h3><p>This is the most important folder in your project. It is where you will spend 99% of your time writing code.</p><ul><li><strong>app/</strong>: This is the heart of your application. It contains your components, services, and routing files. By default,</li></ul><ol><li>app.component.ts: The TypeScript code for your root component.</li><li>app.component.html: The HTML template for your root component.</li><li>app.component.css / .scss: The styles specific to the root component.</li><li>app.routes.ts: The file where you define the navigation routes of your application.</li><li>app.config.ts: The configuration file used to bootstrap the application (replacing the older app.module.ts).</li></ol><ul><li><strong>index.html</strong>: The main HTML file that is served when someone visits your site. You rarely need to change this file. Angular dynamically injects your application into the &lt;app-root&gt; tag found inside.</li><li><strong>main.ts</strong>: The main entry point of your application. It tells Angular how to start (bootstrap) the application using the configuration in app.config.ts.</li><li><strong>styles.css / </strong><strong>styles.scss</strong>: This is your global stylesheet. Any CSS you write here will affect the entire application, unlike component-specific styles.</li></ul><h3>3. Important Configuration Files (Root Directory)</h3><p>Outside the src/ folder, you will find several configuration files.</p><ul><li><strong>angular.json</strong>: This is the workspace configuration file. It tells the Angular CLI how to build, serve, and test your project. If you need to add external CSS libraries (like Bootstrap) or custom scripts, you configure them here.</li><li><strong>package.json</strong>: This file contains meta-data about your project. It lists all the dependencies (libraries your app needs to run) and devDependencies (tools needed only during development). It also contains the npm scripts (like npm start or npm run build).</li><li><strong>tsconfig.json</strong>: The main configuration file for the TypeScript compiler. It dictates how your TypeScript code should be converted into the JavaScript code that browsers can understand.</li><li><strong>.gitignore</strong>: Specifies intentionally untracked files that Git should ignore (like node_modules/ or build output folders).</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fc58b7d30609" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Setting Up a Local Development Environment (Chapter-2)]]></title>
            <link>https://medium.com/@kavindachirath17/setting-up-a-local-development-environment-part-2-18048d55aecc?source=rss-2aa8757d27f4------2</link>
            <guid isPermaLink="false">https://medium.com/p/18048d55aecc</guid>
            <category><![CDATA[angular-install]]></category>
            <category><![CDATA[angular]]></category>
            <category><![CDATA[locally-setup]]></category>
            <category><![CDATA[installation]]></category>
            <dc:creator><![CDATA[Kavinda-chirath]]></dc:creator>
            <pubDate>Fri, 22 May 2026 18:52:29 GMT</pubDate>
            <atom:updated>2026-05-25T16:16:53.753Z</atom:updated>
            <content:encoded><![CDATA[<p>For building real applications, you will need to set up your machine locally.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NkUtraDsi8ZRA6G2VfwmWg.png" /><figcaption>AI generated Image</figcaption></figure><ol><li><strong>Node.js </strong>: recommend installing a recent version (v18.19.0 or newer).</li><li><strong>Text Editor</strong>: <strong>Visual Studio Code (VS Code)</strong> is highly recommended.</li><li><strong>Terminal</strong>: You will need a command-line interface to run Angular CLI commands. (we can get free terminal with vs code)</li></ol><h4>Installing Node.js</h4><p>The presenter guides you through the process of downloading Node.js:</p><ul><li>Visit <a href="https://nodejs.org/">nodejs.org</a> to find the appropriate download for your operating system (Windows, macOS, or Linux).</li><li>Click Download Tab and Select LTS (Long Time Support) version and then Click Download.</li><li>After Can be Install That like Normal Software Installation , also check whether Successfully Installed.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/595/1*7GmcG7BxOfUjmyD65ZFIOg.png" /></figure><h4>Installing the Angular CLI</h4><ul><li>Visit <a href="https://angular.dev/installation">Angular .dev</a> Website and Install Angular CLI . Open Terminal and Copy this Command and Press Enter then Angular will download.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1003/1*Z4dnh1jP4gwML1YuWcHUpQ.png" /></figure><ul><li>To Check Version Type <strong>ng — version</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/598/1*poMTUk2PdL_D3ptyACjeoA.png" /></figure><h4><strong>Install VS code</strong></h4><p>Visit <a href="https://code.visualstudio.com/">vs code official website</a> and Install that.(It is Easy)</p><h4>Create a New Project</h4><p>Select Particular Folder and then Type This Command</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/440/1*s8qFBHGeSNTw12EhdrAMqQ.png" /></figure><ul><li>Then Open The Project from vs code .</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=18048d55aecc" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[1. What is Angular?]]></title>
            <link>https://medium.com/@kavindachirath17/1-what-is-angular-9f70cfc77417?source=rss-2aa8757d27f4------2</link>
            <guid isPermaLink="false">https://medium.com/p/9f70cfc77417</guid>
            <category><![CDATA[angular]]></category>
            <category><![CDATA[angular-for-beginners]]></category>
            <category><![CDATA[what-is-angular]]></category>
            <dc:creator><![CDATA[Kavinda-chirath]]></dc:creator>
            <pubDate>Mon, 18 May 2026 07:06:09 GMT</pubDate>
            <atom:updated>2026-05-18T07:06:09.042Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XzQtHdDQ9ISZOyRmmHR28Q.png" /><figcaption>This Is AI Generated Image</figcaption></figure><p>Angular is a popular, open-source web application development <strong>framework</strong> developed and maintained by <strong>Google</strong>. It is primarily used for building dynamic, <strong>Single-Page Applications (SPAs)</strong> and mobile applications.</p><p><strong>What is a Single-Page Application (SPA)?</strong> In a traditional website, clicking a link or navigating to a new section requires the entire webpage to reload from the server. In a Single-Page Application (like those built with Angular), the page does not reload. Instead, only the specific content area changes dynamically, resulting in a much faster, smoother, and app-like user experience.</p><h3>2. AngularJS vs. Angular: What’s the Difference?</h3><p>A common point of confusion for beginners is the difference between “AngularJS” and “Angular.”</p><ul><li><strong>AngularJS (v1):</strong> Released by Google in 2010. It was built using standard JavaScript.</li><li><strong>Angular (v2 and beyond):</strong> In 2016, Google decided to completely rewrite the framework from scratch to make it more modern and efficient. Starting from version 2 onwards, it is simply called “Angular” and is built using TypeScript instead of JavaScript. Currently, it receives major updates every 6 months (up to version 18+).</li></ul><h3>3. Framework vs. Library</h3><p>To understand Angular, you must understand the difference between a framework and a library:</p><ul><li><strong>Library (e.g., React, jQuery):</strong> A library is a collection of pre-written code that you can use to solve specific problems. It is generally smaller, simpler, and does not force you into a specific architecture. However, to build a full app, you have to manually combine it with other third-party tools (for routing, HTTP calls, etc.).</li><li><strong>Framework (e.g., Angular, Django, Spring):</strong> A framework is larger and comes with multiple built-in features and tools. It provides a complete, out-of-the-box solution with a predefined architecture. When you use Angular, you get built-in routing, HTTP client, and form handling without needing to install external tools.</li></ul><h3>4. Why Use Angular?</h3><p>Here are the main reasons developers and companies choose Angular:</p><ol><li><strong>Component-Based Architecture:</strong> Angular apps are built using components. You break down your UI into small, independent pieces (e.g., a Navbar component, a Sidebar component, a Chart component). This makes the code highly reusable, easier to manage, and simple to test.</li><li><strong>Fully Featured:</strong> It provides everything you need to build a massive enterprise application right out of the box.</li><li><strong>Built-in Unit Testing:</strong> Angular comes with built-in testing tools like Jasmine and Karma, ensuring your application is bug-free and reliable.</li><li><strong>Backed by Tech Giants:</strong> It is developed by Google, and it utilizes TypeScript, which is developed by Microsoft.</li><li><strong>Large Community:</strong> Being open-source and highly popular, it has a massive community. If you run into a bug, a quick search on Stack Overflow or Google will almost certainly yield a solution.</li></ol><h3>5. The Core Technologies Behind Angular</h3><p>To work with Angular, you rely on two foundational technologies:</p><h3>TypeScript</h3><p>Angular is written in <strong>TypeScript</strong>. Developed by Microsoft, TypeScript is a superset of JavaScript. The main advantage of TypeScript is that it introduces <strong>Static Typing</strong>. In standard JavaScript, you can assign a string to a variable that was previously a number, which can cause runtime errors. TypeScript catches these errors at <em>compile-time</em>, warning you before you even run the code.</p><h3>Node.js (and NPM)</h3><p>You also need to install <strong>Node.js</strong>. While Node.js is famous for backend development, Angular uses it for its tooling. Specifically, Node provides <strong>NPM (Node Package Manager)</strong>. NPM allows you to easily install and manage Angular ’s dependencies, as well as the <strong>Angular CLI</strong> (Command Line Interface), which you will use to create and run your Angular projects.</p><h3>6. Who Uses Angular?</h3><p>Because of its robustness and scalability, Angular is heavily used in the enterprise world. Some of the major companies that rely on Angular include:</p><ul><li>Samsung</li><li>Forbes</li><li>PayPal</li><li>Gmail (Google)</li><li>Upwork</li><li>Netflix</li><li>Deutsche Bank</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9f70cfc77417" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>