<?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: Siddharth2k14</title>
    <description>The latest articles on DEV Community by Siddharth2k14 (@siddharth2k14).</description>
    <link>https://dev.to/siddharth2k14</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%2F1057983%2F49448912-4d71-422f-a20b-b7b21e48a8f1.png</url>
      <title>DEV Community: Siddharth2k14</title>
      <link>https://dev.to/siddharth2k14</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/siddharth2k14"/>
    <language>en</language>
    <item>
      <title>Online Exam Portal</title>
      <dc:creator>Siddharth2k14</dc:creator>
      <pubDate>Wed, 06 Aug 2025 21:47:14 +0000</pubDate>
      <link>https://dev.to/siddharth2k14/online-exam-portal-2njo</link>
      <guid>https://dev.to/siddharth2k14/online-exam-portal-2njo</guid>
      <description>&lt;p&gt;This project serves as the frontend interface for the Online Exam Portal, providing a seamless and intuitive experience for both students and administrators.&lt;/p&gt;

&lt;h2&gt;
  
  
  Purpose
&lt;/h2&gt;

&lt;p&gt;The primary goal of this client application is to offer a robust and user-friendly platform for managing and participating in online examinations. It facilitates:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;Student Experience:&lt;/strong&gt; Easy access to available exams, secure exam participation, and clear review of results and history.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Administrator Experience:&lt;/strong&gt; Efficient creation, management, and scheduling of exams, along with performance analytics.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Core Technologies
&lt;/h2&gt;

&lt;p&gt;This client application is built using modern web technologies:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;React:&lt;/strong&gt; A declarative JavaScript library for building user interfaces.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;React Router:&lt;/strong&gt; For handling navigation and routing within the single-page application.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Redux Toolkit:&lt;/strong&gt; For efficient state management, particularly for authentication and exam data.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Material UI (MUI):&lt;/strong&gt; A popular React UI framework for building aesthetically pleasing and responsive components.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Axios:&lt;/strong&gt; A promise-based HTTP client for making requests to the backend API.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;ESLint &amp;amp; Prettier:&lt;/strong&gt; For code linting and formatting, ensuring code quality and consistency.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Project Structure
&lt;/h2&gt;

&lt;p&gt;The project follows a well-organized directory structure to promote maintainability and scalability:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;online-exam-portal-client/
├── public/
│   └── index.html             # Main HTML entry point
├── src/
│   ├── assets/                # Static assets like images, markdown files
│   ├── components/            # Reusable UI components (e.g., NavBar, Auth forms, Exam cards)
│   │   ├── AdminPage/
│   │   ├── Authentication/
│   │   ├── Exam Creation/
│   │   ├── Manage Exams/
│   │   ├── NavBar/
│   │   ├── SideBar/
│   │   ├── StudentPage/
│   │   └── ...
│   ├── pages/                 # Top-level page components (e.g., Home, About, AdminDashboard, StudentDashboard)
│   │   ├── admin/
│   │   └── student/
│   ├── redux/                 # Redux store configuration and slices (auth, exams, questions)
│   │   ├── authSlice.js
│   │   ├── examSlice.js
│   │   ├── questionSlice.js
│   │   └── store.js
│   ├── App.css                # Global styles for the App component
│   ├── App.jsx                # Main application component with routing
│   ├── index.css              # Global CSS resets and base styles
│   ├── main.jsx               # Entry point for React application
│   ├── ThemeContext.jsx       # Context for managing theme (light/dark mode)
│   └── ...
├── eslint.config.js           # ESLint configuration
├── index.html                 # Public HTML file
├── manifest.json              # Web app manifest
├── vite.config.js             # Vite build tool configuration (if used)
└── package.json               # Project dependencies and scripts
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Key Features &amp;amp; Components
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Authentication
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;Login (&lt;code&gt;src/components/Authentication/Login/Login.jsx&lt;/code&gt;):&lt;/strong&gt; Handles user authentication via email and password. Supports role-based redirection to student or admin dashboards.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Signup (&lt;code&gt;src/components/Authentication/Signup/Signup.jsx&lt;/code&gt;):&lt;/strong&gt; Allows new users to register with name, email, and password.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Forget Password (&lt;code&gt;src/components/Authentication/Forget Password/ForgetPassword.jsx&lt;/code&gt;):&lt;/strong&gt; Provides a mechanism for users to reset their passwords.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Navigation
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;NavBar (&lt;code&gt;src/components/NavBar/NavBar.jsx&lt;/code&gt;):&lt;/strong&gt; A persistent navigation bar providing access to Home, About, Contact, Login/Signup, and Logout functionality. It adapts its display based on user authentication status and screen size.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;SideBar (&lt;code&gt;src/components/SideBar/SideBar.jsx&lt;/code&gt;):&lt;/strong&gt; A contextual sidebar that appears on dashboard pages (Admin and Student). It dynamically displays relevant navigation options based on the user's role and the current section.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Admin Functionality
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;AdminPage (&lt;code&gt;src/components/AdminPage/AdminPage.jsx&lt;/code&gt;):&lt;/strong&gt; The main container for admin-specific views, managed by the &lt;code&gt;SideBar&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Exam Creation (&lt;code&gt;src/components/Exam Creation/ExamCreation.jsx&lt;/code&gt;):&lt;/strong&gt; Allows administrators to initiate the creation of new exams, specifying the title and type (Objective/Subjective).&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Objective Exam Creation (&lt;code&gt;src/components/Objective Exam Creation/ObjectiveExamCreation.jsx&lt;/code&gt;):&lt;/strong&gt; Facilitates the creation of objective (MCQ) questions, including options and correct answer selection.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Subjective Exam Creation (&lt;code&gt;src/components/Subjective Exam Creation/SubjectiveExamCreation.jsx&lt;/code&gt;):&lt;/strong&gt; Enables the creation of subjective questions with corresponding answers.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Manage Exams (&lt;code&gt;src/components/Manage Exams/ManageExam.jsx&lt;/code&gt;):&lt;/strong&gt; Provides a view of all created exams, with options to view details or delete them.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;View Exam (&lt;code&gt;src/components/Manage Exams/ViewExam.jsx&lt;/code&gt;):&lt;/strong&gt; Displays the detailed structure of a selected exam, including all questions and options/answers.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Student Functionality
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;StudentPage (&lt;code&gt;src/components/StudentPage/StudentPage.jsx&lt;/code&gt;):&lt;/strong&gt; The main container for student-specific views, managed by the &lt;code&gt;SideBar&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Exams Page (&lt;code&gt;src/components/ExamsPage/ExamsPage.jsx&lt;/code&gt;):&lt;/strong&gt; Lists available exams for students, with filtering options for subject and type.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Start Exam (&lt;code&gt;src/components/StartExam/StartExam.jsx&lt;/code&gt;):&lt;/strong&gt; The interface for students to take an exam, displaying questions one by one and handling objective (MCQ) and subjective answer inputs.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;View Exam (&lt;code&gt;src/components/ViewExam/ViewExam.jsx&lt;/code&gt;):&lt;/strong&gt; Allows students to review their past exam attempts, showing their answers alongside the correct ones.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Result (&lt;code&gt;src/components/Result/Result.jsx&lt;/code&gt;):&lt;/strong&gt; Displays a summary of the student's performance across all taken exams, including scores, percentages, and visual charts.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Shared Functionality
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;Account Settings (&lt;code&gt;src/components/Account Settings/AccountSettings.jsx&lt;/code&gt;):&lt;/strong&gt; Displays the logged-in user's profile information.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Change Password (&lt;code&gt;src/components/Change Password/ChangePassword.jsx&lt;/code&gt;):&lt;/strong&gt; Allows users to update their password.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  State Management (Redux)
&lt;/h2&gt;

&lt;p&gt;The &lt;code&gt;src/redux&lt;/code&gt; directory houses the Redux store and individual slice reducers for managing application state:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;&lt;code&gt;authSlice.js&lt;/code&gt;:&lt;/strong&gt; Manages authentication state, including user information, token, role, loading status, and errors. It handles login and signup asynchronous operations.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;&lt;code&gt;examSlice.js&lt;/code&gt;:&lt;/strong&gt; Manages the state of exams being created by administrators, including exam titles and associated questions.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;&lt;code&gt;questionSlice.js&lt;/code&gt;:&lt;/strong&gt; Manages a temporary list of questions during the exam creation process.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;&lt;code&gt;subjectiveExamSlice.js&lt;/code&gt;:&lt;/strong&gt; Specifically manages the state for subjective questions during exam creation.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Integration Point:&lt;/strong&gt; The &lt;code&gt;authSlice&lt;/code&gt; is crucial for determining user roles and controlling access to protected routes via &lt;code&gt;PrivateRoute.jsx&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Routing
&lt;/h2&gt;

&lt;p&gt;The application uses &lt;code&gt;react-router-dom&lt;/code&gt; for client-side routing. Key routes are defined in &lt;code&gt;src/App.jsx&lt;/code&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;Public Routes:&lt;/strong&gt; &lt;code&gt;/&lt;/code&gt;, &lt;code&gt;/signup&lt;/code&gt;, &lt;code&gt;/login&lt;/code&gt;, &lt;code&gt;/about&lt;/code&gt;, &lt;code&gt;/contact&lt;/code&gt;, &lt;code&gt;/forgetPassword&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Protected Admin Routes:&lt;/strong&gt; &lt;code&gt;/admin/dashboard&lt;/code&gt;, &lt;code&gt;/exam-creation/objective&lt;/code&gt;, &lt;code&gt;/exam-creation/subjective&lt;/code&gt;, &lt;code&gt;/manage-exams/:examTitle&lt;/code&gt;. These routes are protected by &lt;code&gt;PrivateRoute&lt;/code&gt; and require the 'admin' role.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Protected Student Routes:&lt;/strong&gt; &lt;code&gt;/student/dashboard&lt;/code&gt;, &lt;code&gt;/start-exam/:examTitle&lt;/code&gt;, &lt;code&gt;/exam/:examTitle/review&lt;/code&gt;. These routes are protected by &lt;code&gt;PrivateRoute&lt;/code&gt; and require the 'student' role.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Shared Protected Routes:&lt;/strong&gt; &lt;code&gt;/change-password&lt;/code&gt;. Accessible by both 'admin' and 'student'.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;code&gt;PrivateRoute.jsx&lt;/code&gt;&lt;/strong&gt; is a custom component that checks for a valid token and role before rendering the child routes, redirecting to &lt;code&gt;/login&lt;/code&gt; or &lt;code&gt;/&lt;/code&gt; if unauthorized.&lt;/p&gt;

&lt;h2&gt;
  
  
  Best Practices &amp;amp; Usage Patterns
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;Component Reusability:&lt;/strong&gt; Components are designed to be modular and reusable across different parts of the application (e.g., &lt;code&gt;NavBar&lt;/code&gt;, &lt;code&gt;Footer&lt;/code&gt;, &lt;code&gt;Card&lt;/code&gt; components).&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Lazy Loading:&lt;/strong&gt; For performance optimization, route-based code splitting is implemented using &lt;code&gt;React.lazy&lt;/code&gt; and &lt;code&gt;Suspense&lt;/code&gt; for components that are not immediately needed (e.g., dashboard pages, exam creation forms).&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Theme Context:&lt;/strong&gt; The &lt;code&gt;ThemeContext.jsx&lt;/code&gt; provides a way to manage and toggle between light and dark modes globally, affecting the application's appearance.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Error Handling:&lt;/strong&gt; API errors and form validation errors are handled gracefully with user feedback mechanisms like Snackbars and Alerts.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;State Management:&lt;/strong&gt; Redux Toolkit is used for global state, while local component state (&lt;code&gt;useState&lt;/code&gt;) is used for UI-specific states.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;LocalStorage:&lt;/strong&gt; Used for persisting authentication tokens and exam history to provide a seamless experience across sessions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Common Pitfalls &amp;amp; Gotchas
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;API Endpoint Consistency:&lt;/strong&gt; Ensure that API endpoints used in the client (&lt;code&gt;https://online-exam-portal-server.onrender.com/api/...&lt;/code&gt;) are correctly matched with the backend implementation.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Role Management:&lt;/strong&gt; The client relies on the backend to correctly assign and return user roles. Incorrect role assignments on the backend can lead to access issues.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;State Synchronization:&lt;/strong&gt; Be mindful of synchronizing state between Redux, local component state, and &lt;code&gt;localStorage&lt;/code&gt;, especially during authentication and exam history management.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Form Validation:&lt;/strong&gt; Implement comprehensive client-side validation to provide immediate feedback to users, but always rely on server-side validation for security.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;Conditional Rendering:&lt;/strong&gt; Ensure that components and UI elements are rendered correctly based on user roles and authentication status.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This documentation provides a foundational understanding of the &lt;code&gt;online-exam-portal-client&lt;/code&gt; repository. For detailed implementation specifics, refer to my github repo &lt;a href="https://github.com/Siddharth2k14/online-exam-portal-client/tree/ce234bfeea91856277480f6af3077e7cc066eb62" rel="noopener noreferrer"&gt;https://github.com/Siddharth2k14/online-exam-portal-client/tree/ce234bfeea91856277480f6af3077e7cc066eb62&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>About Online Exam Portal project -&gt; The ExamMaster</title>
      <dc:creator>Siddharth2k14</dc:creator>
      <pubDate>Sun, 06 Jul 2025 19:34:41 +0000</pubDate>
      <link>https://dev.to/siddharth2k14/about-online-exam-portal-project-the-exammaster-lim</link>
      <guid>https://dev.to/siddharth2k14/about-online-exam-portal-project-the-exammaster-lim</guid>
      <description>&lt;p&gt;🚀 Building My Online Exam Portal: A Developer’s Journey (Work in Progress!) 🎓&lt;br&gt;
Over the last few weeks, I’ve been deeply engaged in building an Online Exam Portal — a platform crafted to simplify exam creation, participation, and result tracking for students and admins.&lt;br&gt;
💡 The Vision:&lt;br&gt;
To create a full-stack application where:&lt;br&gt;
🧑‍🎓 Students can take objective &amp;amp; subjective exams, see instant results, and track their history&lt;br&gt;
🧑‍💼 Admins can create exams, view submissions, and manage everything in a streamlined dashboard&lt;br&gt;
🛠️ The Tech Stack Evolution:&lt;br&gt;
Choosing the right stack was the hardest part.&lt;br&gt;
Initially, I explored Firebase and Supabase for their real-time capabilities and plug-and-play setup. However, I quickly hit walls:&lt;br&gt;
🔐 Authentication quirks and limitations in customization&lt;br&gt;
📦 Difficulty modeling data for scalable exam structures&lt;br&gt;
📉 Too much reliance on vendor-specific architecture&lt;br&gt;
This led to multiple revisions and eventually a complete pivot toward a more flexible and developer-controlled stack:&lt;br&gt;
Frontend: React.js + Vite ⚛️&lt;br&gt;
Backend: Node.js + Express.js 🚂&lt;br&gt;
Database: MongoDB (left Firebase &amp;amp; Supabase behind!) 🍃&lt;br&gt;
State Management: Redux Toolkit 💾&lt;br&gt;
UI Library: Material UI (for sleek, responsive design) 🎨&lt;br&gt;
🔑 Core Features So Far:&lt;br&gt;
✅ Secure authentication with role-based access (student/admin)&lt;br&gt;
 ✅ Objective &amp;amp; Subjective exam creation&lt;br&gt;
 ✅ Real-time exam participation and scoring&lt;br&gt;
 ✅ Detailed performance insights and analytics&lt;br&gt;
 ✅ Exam history tracking (locally and persistently)&lt;br&gt;
⚠️ Challenges I Faced:&lt;br&gt;
Tech Stack Paralysis: Picking between ease (Firebase) vs. flexibility (MongoDB &amp;amp; custom backend)&lt;br&gt;
Auth Integration: Handling secure, custom login flows was harder than anticipated&lt;br&gt;
Data Migration: Shifting from Supabase/Firebase to MongoDB was painful, but 100% worth it&lt;br&gt;
State Syncing: Redux taught me a lot about clean state management across complex UI flows&lt;br&gt;
⏳ Still a Work in Progress!&lt;br&gt;
I’m refining UI/UX, adding advanced features (like scheduling &amp;amp; result analysis), and aiming for a polished MVP soon.&lt;br&gt;
 This has been an advantageous learning experience, and I’m excited to keep pushing forward!&lt;br&gt;
🔗 &lt;a href="https://github.com/Siddharth2k14/online-exam-portal" rel="noopener noreferrer"&gt;https://github.com/Siddharth2k14/online-exam-portal&lt;/a&gt;&lt;br&gt;
Let’s connect if you’re building something similar, interested in collaborating, or just want to nerd out over dev stuff 😄&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
