<?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 Anujbansal on Medium]]></title>
        <description><![CDATA[Stories by Anujbansal on Medium]]></description>
        <link>https://medium.com/@anujbansaldev?source=rss-76de0d5add9c------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*NPqLBRA_CEopCR5c</url>
            <title>Stories by Anujbansal on Medium</title>
            <link>https://medium.com/@anujbansaldev?source=rss-76de0d5add9c------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 20 Nov 2026 21:08:32 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@anujbansaldev/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[Backend, APIs & RBAC Security: Designing Secure Web APIs]]></title>
            <link>https://medium.com/@anujbansaldev/backend-apis-rbac-security-designing-secure-web-apis-72d8e0f4e5ee?source=rss-76de0d5add9c------2</link>
            <guid isPermaLink="false">https://medium.com/p/72d8e0f4e5ee</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[authentication]]></category>
            <category><![CDATA[api-security]]></category>
            <category><![CDATA[backend-development]]></category>
            <category><![CDATA[expressjs]]></category>
            <dc:creator><![CDATA[Anujbansal]]></dc:creator>
            <pubDate>Sat, 12 Sep 2026 04:31:02 GMT</pubDate>
            <atom:updated>2026-09-12T04:31:02.928Z</atom:updated>
            <content:encoded><![CDATA[<p>Why authentication isn’t enough and where authorization actually belongs.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_wFPILXAOUkStlFkDW0CaA.png" /></figure><p>Authentication doesn’t make an API secure by itself.</p><p>It answers one question: Who are you?</p><p>A production API also needs to answer: What are you allowed to do?</p><p>And sometimes: Can you perform that action on this specific resource?</p><p>That’s where authorization and RBAC become important.</p><p>## Authentication vs authorization</p><p>Authentication establishes identity. Authorization establishes permissions.</p><p>A user may successfully log into an application but still have no permission to delete another user’s account.</p><p>## Don’t rely on the frontend</p><p>Hiding an administrative button doesn’t prevent someone from making the API request manually.</p><p>The backend must be the final authority.</p><p>## RBAC</p><p>Role-Based Access Control provides a structured model:</p><p>User → Role → Permission → Resource/Action</p><p>For example:</p><p>Admin → users.read, users.create, users.update, users.delete<br>Editor → posts.read, posts.create, posts.update<br>User → profile.update</p><p>## Middleware</p><p>A typical Express.js flow:</p><p>Request → Authentication → RBAC → Validation → Controller → Business Logic → Database</p><p>The benefit is consistency.</p><p>## But RBAC isn’t enough</p><p>For GET /users/123/profile, a user may have permission to read profiles, but should they be allowed to read this particular profile?</p><p>That’s resource-level authorization.</p><p>The application may need to evaluate role, ownership, relationship and requested action.</p><p>## Validation</p><p>Authorization doesn’t replace input validation. Validate request bodies, query parameters, route parameters, data types and business constraints.</p><p>## Rate limiting</p><p>Rate limiting can help reduce brute-force attempts, excessive requests and resource exhaustion.</p><p>## Error handling and logging</p><p>Avoid exposing sensitive internal details through production error responses. Log important security events server-side.</p><p>## Security is layered</p><p>A secure API requires multiple controls working together:</p><p>Authentication + Authorization + Validation + Resource Controls + Rate Limiting + Logging</p><p>## Final thought</p><p>The frontend can tell users what they are allowed to do.</p><p>The backend must enforce it.</p><p>Full technical breakdown:<br>https://www.anujbansaldev.in/blog/building-production-ready-web-application-2026#backend</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=72d8e0f4e5ee" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Mastering React Server Components: Understanding the Server/Client Boundary]]></title>
            <link>https://medium.com/@anujbansaldev/mastering-react-server-components-understanding-the-server-client-boundary-3c12724fe3f6?source=rss-76de0d5add9c------2</link>
            <guid isPermaLink="false">https://medium.com/p/3c12724fe3f6</guid>
            <category><![CDATA[nextjs]]></category>
            <category><![CDATA[react-server-component]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[frontend-architecture]]></category>
            <dc:creator><![CDATA[Anujbansal]]></dc:creator>
            <pubDate>Tue, 08 Sep 2026 04:31:02 GMT</pubDate>
            <atom:updated>2026-09-08T04:31:02.994Z</atom:updated>
            <content:encoded><![CDATA[<p>The mental model I use to decide what belongs on the server and what belongs in the browser.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DzXLwmLFlMx1oKzneFSs3g.png" /></figure><p>React Server Components introduce a significant change in how we think about React applications.</p><p>The important part isn’t simply that components can render on the server.</p><p>The bigger architectural question is:</p><p>What actually needs to run in the browser?</p><p>That question influences component design, data fetching, performance and application architecture.</p><p>The Server/Client mental model</p><p>A simplified model looks like this:</p><p>Server Components → Server → Client Components → Browser</p><p>Server Components are useful for UI that doesn’t require browser-side interaction.</p><p>Client Components are useful when the interface requires things such as:</p><p>- State<br>- Event handlers<br>- Browser APIs<br>- Client-side effects<br>- Interactive behavior</p><p>The challenge is deciding where the boundary should exist.</p><p>Don’t make everything a Client Component</p><p>One common mistake is treating `”use client”` as the default solution.</p><p>Instead, start by keeping components on the server when possible.</p><p>Move a component across the client boundary when it actually requires browser-side capabilities.</p><p>This makes the architecture more intentional.</p><p>Why this matters</p><p>The Server/Client boundary affects more than rendering.</p><p>It can influence:</p><p>Bundle size</p><p>Unnecessary client-side code means more work for the browser.</p><p>Data fetching</p><p>Server-side data access can simplify certain application flows.</p><p>Component architecture</p><p>Components now have an additional architectural property: where they execute.</p><p>Performance</p><p>Reducing unnecessary client-side work can improve the browser’s workload.</p><p>Client Components still matter</p><p>RSC doesn’t mean Client Components are bad.</p><p>Interactive UI still needs them.</p><p>A dashboard might look like:</p><p>Dashboard<br>│<br>├── Server<br>│ ├── Header<br>│ ├── Statistics<br>│ └── Data<br>│<br>└── Client<br> ├── Filters<br> └── Interactive Controls</p><p>The objective isn’t to eliminate the client.</p><p>It’s to keep the client boundary intentional.</p><p>The questions I ask</p><p>When building a component, I ask:</p><p>Does it need state?<br>Does it need event handlers?<br>Does it use browser APIs?<br>Does it need client-side effects?<br>Can the server handle its data requirements?<br>Does this dependency actually need to run in the browser?</p><p>These questions are often more useful than simply memorizing RSC rules.</p><p>RSC is an architectural model</p><p>The biggest shift is mental.</p><p>Instead of thinking:</p><p>“Everything is a React component.”</p><p>I think:</p><p>“Every component has an execution environment.”</p><p>That changes how we approach frontend architecture.</p><p>The goal is not maximum use of Server Components.</p><p>The goal is choosing the right boundary.</p><p>Full technical breakdown:</p><p><a href="https://www.anujbansaldev.in/blog/mastering-react-server-components">https://www.anujbansaldev.in/blog/mastering-react-server-components</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3c12724fe3f6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Frontend & UX: Building Interfaces That Scale With the Product]]></title>
            <link>https://medium.com/@anujbansaldev/frontend-ux-building-interfaces-that-scale-with-the-product-05c5e6cd3642?source=rss-76de0d5add9c------2</link>
            <guid isPermaLink="false">https://medium.com/p/05c5e6cd3642</guid>
            <dc:creator><![CDATA[Anujbansal]]></dc:creator>
            <pubDate>Fri, 04 Sep 2026 04:31:05 GMT</pubDate>
            <atom:updated>2026-09-04T04:31:05.066Z</atom:updated>
            <content:encoded><![CDATA[<p>Why frontend architecture, performance and user experience should be designed together.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qmwTwxyXFh14Bbs5CAS_rw.png" /></figure><p>A frontend can be technically well-built and still be a poor product.</p><p>The React components may be reusable.</p><p>The Next.js architecture may be clean.</p><p>The CSS may be organized.</p><p>But if users struggle to navigate the application, wait too long for content or don’t understand what to do next, the frontend has failed where it matters most.</p><p>Frontend development is therefore not just a UI problem.</p><p>It is an engineering and UX problem.</p><p>## Start with the user journey</p><p>Before designing components, understand what the user is trying to accomplish.</p><p>The interface should make that journey obvious.</p><p>Navigation, hierarchy, forms, feedback and content should work together rather than existing as independent UI elements.</p><p>## Build components around responsibility</p><p>Reusable components are valuable, but excessive abstraction can make a codebase harder to understand.</p><p>Components should have clear responsibilities and predictable behavior.</p><p>The objective isn’t maximum reuse.</p><p>It is useful reuse.</p><p>## Responsive design</p><p>A responsive interface shouldn’t simply shrink a desktop layout.</p><p>Different screen sizes change how users interact with the product.</p><p>Navigation, tables, forms, cards and interactive elements may all require different treatment.</p><p>## Design the states</p><p>A production interface needs more than its successful state.</p><p>Consider:</p><p>- Loading<br>- Empty<br>- Error<br>- Success<br>- Disabled<br>- Partial data</p><p>These states determine how users understand what the application is doing.</p><p>## Performance is UX</p><p>Users don’t experience your architecture diagram.</p><p>They experience how quickly the page becomes usable.</p><p>With React and Next.js, performance decisions can include:</p><p>- Server rendering<br>- Image optimization<br>- Code splitting<br>- Lazy loading<br>- Efficient data fetching<br>- Caching<br>- Reducing unnecessary client-side JavaScript</p><p>Performance shouldn’t be a final cleanup task.</p><p>It should influence architecture from the beginning.</p><p>## Accessibility</p><p>Accessibility is another part of product quality.</p><p>Semantic HTML, keyboard navigation, focus management, readable contrast and meaningful labels make interfaces usable by a much wider range of people.</p><p>## Design systems</p><p>As applications grow, visual inconsistency becomes expensive.</p><p>A design system creates reusable patterns for:</p><p>- Typography<br>- Colors<br>- Spacing<br>- Buttons<br>- Inputs<br>- Cards<br>- Navigation<br>- Feedback states</p><p>This benefits both users and developers.</p><p>## Animation needs a purpose</p><p>Animation can improve an interface when it communicates state or creates continuity between interactions.</p><p>But animation without purpose becomes noise.</p><p>A transition should help users understand what changed.</p><p>## The real goal</p><p>The goal of frontend development isn’t to add more components or create increasingly elaborate interfaces.</p><p>It’s to make the user’s path through the application clear while keeping the implementation maintainable.</p><p>**Good UX + Good architecture + Good performance**</p><p>should work together.</p><p>Full article:</p><p><a href="https://www.anujbansaldev.in/blog/building-production-ready-web-application-2026#frontend">https://www.anujbansaldev.in/blog/building-production-ready-web-application-2026#frontend</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=05c5e6cd3642" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Architecture & Planning: Building a Production-Ready Web Application]]></title>
            <link>https://medium.com/@anujbansaldev/architecture-planning-building-a-production-ready-web-application-9f69a8955952?source=rss-76de0d5add9c------2</link>
            <guid isPermaLink="false">https://medium.com/p/9f69a8955952</guid>
            <category><![CDATA[software-architecture]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[design-systems]]></category>
            <category><![CDATA[nextjs]]></category>
            <dc:creator><![CDATA[Anujbansal]]></dc:creator>
            <pubDate>Tue, 01 Sep 2026 04:31:08 GMT</pubDate>
            <atom:updated>2026-09-01T04:31:08.694Z</atom:updated>
            <content:encoded><![CDATA[<p>The architectural decisions I consider before writing production code.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*or0L5GR44-Y1O2csom6qpA.png" /></figure><h4>A web application can be easy to build and difficult to maintain.</h4><p>That’s usually where architecture becomes important.</p><p>At the beginning of a project, everything is small.</p><p>There may be a few pages, a few APIs and one database.</p><p>Then the application grows.</p><p>Authentication is added.</p><p>Roles are introduced.</p><p>More integrations appear.</p><p>The database becomes larger.</p><p>More developers start contributing.</p><p>Deployment becomes more complicated.</p><p>What looked like a simple application becomes a system with many dependencies.</p><p>That’s why I prefer to think about architecture before implementation.</p><p>For a modern Next.js + Node.js/MERN application, I start with five major areas:</p><p><strong>Frontend → API → Business Logic → Database → Infrastructure</strong></p><p>The objective isn’t to predict every future requirement.</p><p>It’s to establish boundaries that make future changes manageable.</p><h3>Frontend</h3><p>The frontend should primarily deal with presentation, interaction and appropriate client-side state.</p><h3>API</h3><p>The API should establish predictable contracts between the frontend and backend.</p><p>Authentication, authorization, validation, errors, pagination and rate limiting should be considered early.</p><h3>Business logic</h3><p>Business rules shouldn’t be scattered throughout UI components and API handlers.</p><p>Keeping them isolated makes testing and future changes easier.</p><h3>Database</h3><p>Database design should reflect the domain and expected query patterns rather than simply mirroring the UI.</p><h3>Infrastructure</h3><p>Production readiness also includes deployment, environment configuration, logging, monitoring, backups and security.</p><p>The most important lesson is that good architecture doesn’t necessarily mean complex architecture.</p><p>Sometimes the best architecture is simply the one where every responsibility has an obvious place.</p><p>Full article: <a href="https://www.anujbansaldev.in/blog/building-production-ready-web-application-2026">https://www.anujbansaldev.in/blog/building-production-ready-web-application-2026</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9f69a8955952" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>