<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Auth on Jesper Andersen - Blog &amp; DevLog</title><link>https://jespertandersen.github.io/Portfolio/tags/auth/</link><description>Recent content in Auth on Jesper Andersen - Blog &amp; DevLog</description><generator>Hugo -- gohugo.io</generator><language>en</language><managingEditor>cph-ja472@stud.ek.dk (Jesper Andersen)</managingEditor><webMaster>cph-ja472@stud.ek.dk (Jesper Andersen)</webMaster><copyright>© 2026 Jesper Andersen</copyright><lastBuildDate>Mon, 01 Jun 2026 00:00:00 +0000</lastBuildDate><atom:link href="https://jespertandersen.github.io/Portfolio/tags/auth/index.xml" rel="self" type="application/rss+xml"/><item><title>Maintenance Log Frontend - Fifteenth Week: Frontend Final Wrap-Up (From Kickoff to Deployed App)</title><link>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-fifteenthweek/</link><pubDate>Mon, 01 Jun 2026 00:00:00 +0000</pubDate><author>cph-ja472@stud.ek.dk (Jesper Andersen)</author><guid>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-fifteenthweek/</guid><description>&lt;h1 class="relative group"&gt;Devlog Week 15: Frontend Final Wrap-Up (From Kickoff to Deployed App)
 &lt;div id="devlog-week-15-frontend-final-wrap-up-from-kickoff-to-deployed-app" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#devlog-week-15-frontend-final-wrap-up-from-kickoff-to-deployed-app" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h1&gt;
&lt;p&gt;When I wrote the first frontend entry (Week 9), the React app was basically a shell: Vite setup, a layout route, a drawer menu, and a couple of placeholder pages driven by mock data.&lt;/p&gt;</description></item><item><title>Maintenance Log Frontend - Fourteenth Week: Manager/Admin Flows, Create Pages, and Session Expiry Handling</title><link>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-fourteenthweek/</link><pubDate>Wed, 20 May 2026 00:00:00 +0000</pubDate><author>cph-ja472@stud.ek.dk (Jesper Andersen)</author><guid>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-fourteenthweek/</guid><description>&lt;h1 class="relative group"&gt;Devlog Week 14: Manager/Admin Flows, Create Pages, and Session Expiry Handling
 &lt;div id="devlog-week-14-manageradmin-flows-create-pages-and-session-expiry-handling" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#devlog-week-14-manageradmin-flows-create-pages-and-session-expiry-handling" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h1&gt;
&lt;p&gt;This entry covers the manager/admin-facing workflows (create pages and domain admin actions), and ends with a centralized error-handling + session expiry (token expiration) flow to keep UX consistent across the app.&lt;/p&gt;</description></item><item><title>Maintenance Log Frontend - Twelfth Week: User Profiles, Employee Admin Actions, and Form Patterns</title><link>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-twelfthweek/</link><pubDate>Sat, 16 May 2026 00:00:00 +0000</pubDate><author>cph-ja472@stud.ek.dk (Jesper Andersen)</author><guid>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-twelfthweek/</guid><description>&lt;h1 class="relative group"&gt;Devlog Week 12: User Profiles, Employee Admin Actions, and Form Patterns
 &lt;div id="devlog-week-12-user-profiles-employee-admin-actions-and-form-patterns" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#devlog-week-12-user-profiles-employee-admin-actions-and-form-patterns" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h1&gt;
&lt;p&gt;This entry covers the employee-facing parts of the UI: profile views, edit flows, admin actions, and the form patterns used to keep components maintainable.&lt;/p&gt;

&lt;h2 class="relative group"&gt;What Changed
 &lt;div id="what-changed" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#what-changed" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;UserProfile&lt;/code&gt; supports both &amp;ldquo;me&amp;rdquo; and viewing other employees via dynamic route params&lt;/li&gt;
&lt;li&gt;Profile page extracted into focused subcomponents:
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;EditProfileForm&lt;/code&gt;, &lt;code&gt;AdminActions&lt;/code&gt;, &lt;code&gt;PasswordChangeForm&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Form handling uses a mix of controlled inputs and a &lt;code&gt;FormData&lt;/code&gt; approach (when appropriate)&lt;/li&gt;
&lt;li&gt;&lt;code&gt;useEffect&lt;/code&gt; race-condition prevention via an &lt;code&gt;ignore&lt;/code&gt; flag to avoid setting state after unmount&lt;/li&gt;
&lt;li&gt;Admin-only employee actions (deactivate/reactivate) gated by role and disallowed on own profile&lt;/li&gt;
&lt;/ul&gt;
&lt;hr&gt;

&lt;h2 class="relative group"&gt;User Profile: “Me” vs “Other Employee”
 &lt;div id="user-profile-me-vs-other-employee" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#user-profile-me-vs-other-employee" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h2&gt;
&lt;p&gt;The profile route supports multiple entry points:&lt;/p&gt;</description></item><item><title>Maintenance Log Frontend - Tenth Week: Frontend Auth, Routing, and API Client Structure</title><link>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-tenthweek/</link><pubDate>Fri, 08 May 2026 00:00:00 +0000</pubDate><author>cph-ja472@stud.ek.dk (Jesper Andersen)</author><guid>https://jespertandersen.github.io/Portfolio/devlog/maintenancelog-tenthweek/</guid><description>&lt;h1 class="relative group"&gt;Devlog Week 10: Frontend Auth, Routing, and API Client Structure
 &lt;div id="devlog-week-10-frontend-auth-routing-and-api-client-structure" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#devlog-week-10-frontend-auth-routing-and-api-client-structure" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h1&gt;
&lt;p&gt;This entry covers the &amp;ldquo;plumbing&amp;rdquo; for the React frontend: the route layout, guarded routes by role, auth rehydration, and an API layer split by domain.&lt;/p&gt;

&lt;h2 class="relative group"&gt;What Changed
 &lt;div id="what-changed" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#what-changed" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Vite + React + React Router setup with a domain-organized structure (&lt;code&gt;pages/&lt;/code&gt;, &lt;code&gt;components/&lt;/code&gt;, &lt;code&gt;utils/&lt;/code&gt;, &lt;code&gt;context/&lt;/code&gt;, &lt;code&gt;styles/&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Declarative nested routing with a layout route and &lt;code&gt;&amp;lt;Outlet /&amp;gt;&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Auth context for user state, token rehydration, and role checks&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ProtectedRoute&lt;/code&gt; component for nestable route protection&lt;/li&gt;
&lt;li&gt;API layer split by domain with a shared &lt;code&gt;apiRequest()&lt;/code&gt; helper&lt;/li&gt;
&lt;/ul&gt;
&lt;hr&gt;

&lt;h2 class="relative group"&gt;Routing: Nested Layout + Guards
 &lt;div id="routing-nested-layout--guards" class="anchor"&gt;&lt;/div&gt;
 
 &lt;span
 class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;
 &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#routing-nested-layout--guards" aria-label="Anchor"&gt;#&lt;/a&gt;
 &lt;/span&gt;
 
&lt;/h2&gt;
&lt;p&gt;The router is set up as nested routes:&lt;/p&gt;</description></item></channel></rss>