<?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: Kinuri Mahoshadhi Edirisinghe</title>
    <description>The latest articles on DEV Community by Kinuri Mahoshadhi Edirisinghe (@kinuri_mahoshadhiedirisi).</description>
    <link>https://dev.to/kinuri_mahoshadhiedirisi</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.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4059065%2Fcc3afd17-c5dc-4d5f-9336-82f63d3a6da5.jpg</url>
      <title>DEV Community: Kinuri Mahoshadhi Edirisinghe</title>
      <link>https://dev.to/kinuri_mahoshadhiedirisi</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/kinuri_mahoshadhiedirisi"/>
    <language>en</language>
    <item>
      <title>My Comfort Food Project: Interactive Sri Lankan Spicy 🧀 Kottu Calculator! 🍜</title>
      <dc:creator>Kinuri Mahoshadhi Edirisinghe</dc:creator>
      <pubDate>Sun, 02 Aug 2026 13:40:38 +0000</pubDate>
      <link>https://dev.to/kinuri_mahoshadhiedirisi/my-comfort-food-project-interactive-sri-lankan-spicy-kottu-calculator-2gg6</link>
      <guid>https://dev.to/kinuri_mahoshadhiedirisi/my-comfort-food-project-interactive-sri-lankan-spicy-kottu-calculator-2gg6</guid>
      <description>&lt;p&gt;&lt;strong&gt;Hi everyone!&lt;/strong&gt; 🇱🇰&lt;/p&gt;

&lt;p&gt;For the DEV Frontend Challenge: Comfort Food Edition, I wanted to build a web page inspired by the ultimate street comfort food from my home country, Sri Lanka — *&lt;em&gt;Spicy Cheese Kottu!&lt;br&gt;
*&lt;/em&gt;&lt;br&gt;
Kottu is a legendary Sri Lankan street food made with shredded parotta roti, aromatic spices, fresh vegetables, eggs, and meat. In this special version, we add a massive amount of melted cheese to balance out the heavy spice. It's warm, comforting, and the perfect meal for a quiet midnight craving.&lt;/p&gt;
&lt;h3&gt;
  
  
  🚀 Live Demo
&lt;/h3&gt;

&lt;p&gt;You can try out my live interactive web app here:&lt;br&gt;
👉 &lt;strong&gt;&lt;a href="https://edirisinghekinurimahoshadhi-debug.github.io/-kottu-challenge/" rel="noopener noreferrer"&gt;Click Here to See My Cozy Kottu Website&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;h3&gt;
  
  
  What I Built 🛠️
&lt;/h3&gt;

&lt;p&gt;Inspired by a cozy midnight ramen illustration, I created a dark-themed UI featuring a soft glowing moon, stars, a warm lamp effect, and a steaming Kottu bowl. &lt;/p&gt;

&lt;p&gt;I implemented an &lt;strong&gt;Interactive Ingredient Portion Calculator&lt;/strong&gt; using vanilla JavaScript. When a user adjusts the number of servings, the application dynamically calculates the exact amount of Parotta Roti, Melted Cheese, and Chicken needed in real-time!&lt;/p&gt;
&lt;h3&gt;
  
  
  The Code Snippet 💻
&lt;/h3&gt;

&lt;p&gt;Here is the JavaScript logic I used to handle the real-time serving calculations based on the input element:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;servingsInput&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;servings&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;rotiSpan&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;roti&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;cheeseSpan&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;cheese&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;baseRoti&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;baseCheese&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;50&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="nx"&gt;servingsInput&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;addEventListener&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;input&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;servings&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;parseInt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;servingsInput&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nx"&gt;rotiSpan&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;baseRoti&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nx"&gt;servings&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nx"&gt;cheeseSpan&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;textContent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;baseCheese&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="nx"&gt;servings&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Why this is my Comfort Food ❤️
&lt;/h3&gt;

&lt;p&gt;In Sri Lanka, Kottu isn't just food; it's an experience. The rhythmic sound of metal blades chopping the roti on hot iron griddles can be heard down every street at night. Whenever we gather with friends or family after a long day, a warm, cheesy bowl of Kottu always makes us feel right at home.&lt;/p&gt;

&lt;p&gt;I would love to hear your feedback! Have you ever tasted authentic Sri Lankan Kottu or any spicy street food like this? Let me know in the comments below! 🍜🧀&lt;/p&gt;

</description>
      <category>frontendchallenge</category>
      <category>comfortfood</category>
      <category>webdev</category>
      <category>html</category>
    </item>
    <item>
      <title>5 Common CSS Mistakes Beginners Make and How to Fix Them</title>
      <dc:creator>Kinuri Mahoshadhi Edirisinghe</dc:creator>
      <pubDate>Sun, 02 Aug 2026 12:31:08 +0000</pubDate>
      <link>https://dev.to/kinuri_mahoshadhiedirisi/5-common-css-mistakes-beginners-make-and-how-to-fix-them-1b42</link>
      <guid>https://dev.to/kinuri_mahoshadhiedirisi/5-common-css-mistakes-beginners-make-and-how-to-fix-them-1b42</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Learning CSS can feel like magic, but it can also be incredibly frustrating. One minute your website looks perfect, and the next minute, a single line of code breaks the entire layout.If you are struggling to get your web pages to look exactly how you want, don't worry. Here are 5 of the most common CSS mistakes beginners make and exactly how you can fix them.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;strong&gt;1. Forgetting the CSS Box Model (Adding Padding Breaks Width)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;The Mistake&lt;/em&gt;: You set a box's width to 100%, but as soon as you add &lt;code&gt;padding: 20px;&lt;/code&gt; or a border, horizontal scrollbars appear and your layout breaks.Why it happens: By default, CSS adds padding and borders on top of the width you specified. So, 100% width + 20px padding left + 20px padding right = wider than the screen!The Fix: Always use box-sizing: border-box; at the top of your CSS file. This forces the browser to include padding and borders inside the specified width.&lt;/p&gt;

&lt;p&gt;/* Add this to the very top of your CSS file */&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;{
box-sizing: border-box;
margin: 0;
padding: 0;
}&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;2. Confusing Block vs. Inline Elements&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The Mistake: You try to add a vertical margin, width, or height to a &lt;span&gt; or an &lt;a&gt; tag, but nothing changes on the screen.Why it happens: Tags like &lt;span&gt;, &lt;/span&gt;&lt;/a&gt;&lt;a&gt;, and &lt;strong&gt; are inline elements. By default, inline elements ignore top/bottom margins, heights, and widths.The Fix: Change the element's display property to inline-block or block.&lt;/strong&gt;&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;a&gt;&lt;strong&gt;

&lt;p&gt;/* Fix: This will now respect your width and margin settings */&lt;br&gt;
a {&lt;br&gt;
  display: inline-block;&lt;br&gt;
  width: 150px;&lt;br&gt;
  margin-top: 20px;&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Overusing Absolute Positioning (position: absolute)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The Mistake: Using position: absolute; to push elements around the screen until they look "perfect" on your laptop, only to find the layout completely scrambled on a mobile screen.Why it happens: Absolute positioning takes elements out of the normal document flow. It makes your website completely rigid and unresponsive.The Fix: Stop using absolute positioning for general layouts. Instead, learn and use CSS Flexbox or CSS Grid to build flexible layouts.&lt;/p&gt;

&lt;p&gt;/* Instead of absolute position, use Flexbox to center things easily */&lt;br&gt;
.container {&lt;br&gt;
  display: flex;&lt;br&gt;
  justify-content: center;&lt;br&gt;
  align-items: center;&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. Hardcoding Fixed Widths (width: 800px)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The Mistake: Setting major containers or image wrappers to a hardcoded pixel size like width: 1200px;.Why it happens: A fixed pixel width looks great on a large desktop monitor, but when viewed on a smartphone (which usually has a width under 400px), your content will get cut off.The Fix: Use relative units like percentages (%), viewport width (vw), or combine max-width with a percentage.&lt;/p&gt;

&lt;p&gt;/* Fix: The container will shrink safely on smaller mobile screens */&lt;br&gt;
.main-container {&lt;br&gt;
  width: 100%;&lt;br&gt;
  max-width: 1200px; &lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5. Using the Wrong Color and Font Units&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The Mistake: Using px for text sizing everywhere, making it difficult for users with accessibility needs to scale up the text on their browsers.Why it happens: Pixels are absolute units. If a user sets their default browser font larger for better readability, your px fonts will ignore their preference.The Fix: Use rem for font sizes. 1rem is typically equal to the browser's default font size (usually 16px).&lt;/p&gt;

&lt;p&gt;/* Fix: Responsive typography that respects user settings &lt;em&gt;/&lt;br&gt;
h1 {&lt;br&gt;
  font-size: 2.5rem; /&lt;/em&gt; Equals 40px on standard settings &lt;em&gt;/&lt;br&gt;
}&lt;br&gt;
p {&lt;br&gt;
  font-size: 1rem;   /&lt;/em&gt; Equals 16px on standard settings */&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ConclusionCSS&lt;/strong&gt; &lt;br&gt;
&lt;em&gt;isn't broken; it just has specific rules! By using box-sizing: border-box, switching to Flexbox, and using relative units like rem and %, you will instantly eliminate 90% of your layout bugs.What is the most frustrating CSS bug you've encountered so far? Let me know in the comments below!&lt;/em&gt;&lt;/p&gt;

&lt;/strong&gt;&lt;/a&gt;

</description>
      <category>html</category>
      <category>css</category>
      <category>webdev</category>
      <category>bugsmash</category>
    </item>
  </channel>
</rss>
