<?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: Jayash</title>
    <description>The latest articles on DEV Community by Jayash (@jayash101).</description>
    <link>https://dev.to/jayash101</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3273555%2F86d570c6-6b4f-4282-95c3-3c104defc02f.jpeg</url>
      <title>DEV Community: Jayash</title>
      <link>https://dev.to/jayash101</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/jayash101"/>
    <language>en</language>
    <item>
      <title>🚀 Building Mada TodoList with Next.js 15, Redux Toolkit &amp; Tailwind CSS</title>
      <dc:creator>Jayash</dc:creator>
      <pubDate>Wed, 18 Jun 2025 11:45:58 +0000</pubDate>
      <link>https://dev.to/jayash101/building-mada-todolist-with-nextjs-15-redux-toolkit-tailwind-css-3kd7</link>
      <guid>https://dev.to/jayash101/building-mada-todolist-with-nextjs-15-redux-toolkit-tailwind-css-3kd7</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;A simple and modern Todo List app built with performance and UX in mind. Don't get confused. MADA means ADAM in reverse.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  🎯 What is Mada TodoList?
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Mada TodoList&lt;/strong&gt; is a sleek, fast, and responsive task management web application. I built it to sharpen my frontend skills and explore the capabilities of &lt;strong&gt;Next.js 15 with the App Router&lt;/strong&gt;, &lt;strong&gt;Redux Toolkit&lt;/strong&gt;, and &lt;strong&gt;Tailwind CSS&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Despite being simple on the surface, the project packs a full set of practical features — perfect for learning and iterating.&lt;/p&gt;




&lt;h2&gt;
  
  
  ✨ Features
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;✅ Add, edit, and delete tasks&lt;/li&gt;
&lt;li&gt;🔁 Toggle task completion&lt;/li&gt;
&lt;li&gt;🔍 Filter by All | Active | Completed&lt;/li&gt;
&lt;li&gt;🌙 Light/Dark theme toggle with persistent storage&lt;/li&gt;
&lt;li&gt;💾 Save tasks in &lt;code&gt;localStorage&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;📱 Fully responsive layout&lt;/li&gt;
&lt;li&gt;⚡ Client-side only with hydration-safe logic&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛠 Tech Stack
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🧩 Next.js 15 (App Router)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Using &lt;strong&gt;client components&lt;/strong&gt; and &lt;strong&gt;App Router&lt;/strong&gt;, the app is structured around interactive UI and modular design.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  ⚛️ Redux Toolkit
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;State managed via &lt;strong&gt;Redux slices&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;todoSlice&lt;/code&gt; for task management&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;themeSlice&lt;/code&gt; for dark/light mode&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;&lt;p&gt;Integrated with &lt;code&gt;useAppDispatch&lt;/code&gt; and &lt;code&gt;useAppSelector&lt;/code&gt; custom hooks.&lt;/p&gt;&lt;/li&gt;

&lt;/ul&gt;

&lt;h3&gt;
  
  
  🎨 Tailwind CSS
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Used utility classes for styling and layout.&lt;/li&gt;
&lt;li&gt;Supported &lt;strong&gt;dark mode via class strategy&lt;/strong&gt;, triggered by a Redux-controlled theme.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  💡 localStorage (With SSR-safe Access)
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Tasks and theme preference are persisted via &lt;code&gt;localStorage&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Avoided SSR errors by wrapping reads/writes in &lt;code&gt;useEffect&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  📁 Folder Structure
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;mada-todolist/
├── app/
│   └── layout.tsx           # App entry
├── components/
│   ├── Input.tsx
│   ├── List.tsx
│   └── ...
├── store/
│   ├── hooks.ts
│   ├── todo/
│   │   └── todoSlice.ts
│   └── theme/
│       └── themeSlice.ts
├── styles/
│   └── globals.css
└── utils/
    └── storage.ts
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚠️ Challenges Faced
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. &lt;strong&gt;localStorage is not defined&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Accessing &lt;code&gt;localStorage&lt;/code&gt; during SSR crashed the app.&lt;br&gt;
&lt;strong&gt;Fix:&lt;/strong&gt; Moved all &lt;code&gt;localStorage&lt;/code&gt; logic into &lt;code&gt;useEffect&lt;/code&gt;, and avoided preloading data in initial Redux state.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. &lt;strong&gt;Flash of wrong theme on reload&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;On reload, light theme showed for a split second before switching to dark.&lt;br&gt;
&lt;strong&gt;Fix:&lt;/strong&gt; Injected inline script in &lt;code&gt;&amp;lt;head&amp;gt;&lt;/code&gt; to apply saved theme &lt;strong&gt;before React hydration&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. &lt;strong&gt;Redux with hydration&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Redux state and &lt;code&gt;localStorage&lt;/code&gt; needed synchronization post-mount.&lt;br&gt;
&lt;strong&gt;Fix:&lt;/strong&gt; Used an &lt;code&gt;initializeTheme&lt;/code&gt; action and conditionally updated state after mount.&lt;/p&gt;




&lt;h2&gt;
  
  
  🌟 What I Learned
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Clean separation of concerns using slices in Redux Toolkit.&lt;/li&gt;
&lt;li&gt;Dark mode theming using Tailwind + persisted state.&lt;/li&gt;
&lt;li&gt;Next.js 15 App Router with full client-side hydration management.&lt;/li&gt;
&lt;li&gt;Best practices for SSR-safe &lt;code&gt;localStorage&lt;/code&gt; access.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  📌 What's Next?
&lt;/h2&gt;

&lt;p&gt;Some possible extensions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Add drag-and-drop reordering&lt;/li&gt;
&lt;li&gt;Sync tasks with a backend (e.g. Supabase or Firebase)&lt;/li&gt;
&lt;li&gt;Add login/authentication&lt;/li&gt;
&lt;li&gt;Convert into a PWA&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔗 Try it out
&lt;/h2&gt;

&lt;p&gt;GitHub: &lt;a href="https://github.com/jayash101/MADA-Todo-App" rel="noopener noreferrer"&gt;https://github.com/jayash101/MADA-Todo-App&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Live Preview: &lt;a href="https://mada-todo-app.vercel.app/" rel="noopener noreferrer"&gt;Click here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Feel free to explore, fork, or contribute!&lt;/p&gt;




&lt;h2&gt;
  
  
  🙌 Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Small apps like this are great for diving deep into real-world challenges with state management, SSR compatibility, and responsive design. I’d love to hear your thoughts or feedback!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Thanks for reading 🙏&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>react</category>
      <category>nextjs</category>
      <category>typescript</category>
    </item>
  </channel>
</rss>
