Pasupathy Report
Pasupathy Report
AN INTERNSHIP REPORT
Submitted by
PASUPATHY T 962821104064
BACHELOR OF ENGINEERING
in
NOVEMBER 2024
CALL LETTER
i
ATTENDANCE CERTIFICATE
ii
CERTIFICATE
iii
ABSTRACT
and other key front-end technologies, including HTML, CSS, JavaScript, and
advanced topics like conditional rendering, event handling, and styling within
how to create interactive user interfaces and manage data effectively within
React.By the end of the internship, I was able to develop and deploy a fully
ATTENDANCE CERTIFICATE ii
CERTIFICATE iii
ABSTRACT iv
I COMPANY PROFILE 1
II STUDY 8
2.1 INTRODUCTION TO WEB 8
DEVELOPMENT AND TOOLS
v
2.2 BASIC WEB DEVELOPMENT PRACTICE 13
AND FORMS
ADVANCED FEATURES
III MY PROJECTS 24
A LEARNING PLATFORM
vi
LIST OF FIGURES
3.5 Dashboard 44
3.6 Courses 44
3.7 Tasks 45
3.8 Quizzes 45
3.9 Score 46
vii
LIST OF ABBREVIATIONS
PR Pull Request
viii
CHAPTER 1
COMPANY PROFILE
1
1.3 RESEARCH AND TECHNOLOGICAL ADVANCEMENT
2
1.5 CORE MISSION STATEMENT
3
• CSS Modules for scoped and maintainable styles.
• Gained insights into deploying SPAs to local servers for testing and
debugging purposes.
• Gained familiarity with version control using Git for managing codebases
and collaborative workflows.
During the React.js Web Development Internship, the following skills and
outcomes were achieved:
4
1. Technical Proficiency in Front-End Development
• State and lifecycle management with React hooks like useState and
useEffect.
• Developed debugging skills using tools like React DevTools and browser
consoles to resolve issues effectively.
• Gained familiarity with version control using Git, working with branches,
and managing code repositories in a team environment.
6
5. Placement Assistance: We provide support in building resumes, preparing
for technical interviews, and connecting participants with potential
employers.
7
CHAPTER 2
STUDY
Visual Studio Code (VSCode) is one of the most widely used code editors
among web developers. Its powerful features like IntelliSense (auto-completion
of code), integrated terminal, Git support, and a vast library of extensions make
it a favorite choice for both beginners and professionals.
• Git Integration: With built-in Git support, VSCode makes version control
management simple, showing changes in your code and allowing for easy
commits and push operations.
8
• Extensions and Themes: Extensions for additional functionality (like
linting, debugging, and theme customization) and themes for personalized
code appearance help developers enhance productivity.
Installation of React: To begin working with React, you need to install Node.js
and npm (Node Package Manager) first. Then, use the create-react-app command
to generate a new React project:
cd my-app
npm start
This will create a basic project structure, and running npm start will launch a local
development server to view your app in the browser.
HTML is made up of elements, which are defined by tags. These elements are
used to structure the page, and each element can have attributes that provide
additional information.
9
Basic HTML Syntax:
<!DOCTYPE html>
<html>
<head>
</head>
<body>
<h1>Welcome to My Website</h1>
</body>
</html>
In this example:
• Internal CSS: Placed in a <style> block inside the <head> section of the
HTML document.
• External CSS: Placed in separate .css files that are linked to the HTML
document.
Example:
<head>
<style>
body {
background-color: #f4f4f4;
</style>
</head>
11
2.1.9 JAVASCRIPT INTRODUCTION AND OVERVIEW
Example:
alert(message);
JavaScript is the fundamental language used for building web applications, but
React is a specialized library for developing dynamic user interfaces. While
JavaScript is used for manipulating the DOM directly, React helps create
efficient, reusable components that automatically update when data changes,
simplifying complex UI
document.getElementById('btn').addEventListener('click', () => {
alert('Button Clicked');
});
12
const greet = (name) => `Hello, ${name}!`;
console.log(greet('World'));
In this section, we will apply HTML and CSS to create a simple webpage layout.
For example, we can build a page with a header, main content area, and footer.
Example Layout:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Simple Webpage</title>
<style>
</style>
</head>
<body>
13
<header><h1>Welcome to My Webpage</h1></header>
<main>
</main>
<footer><p>Footer Information</p></footer>
</body>
</html>
• React requires external libraries for routing, while Angular has built-in
tools.
14
2.3.3.2 REACTJS VS. VUEJS
render() {
15
const Counter = () => {
};
2.5.1.1 COMPONENTDIDMOUNT
useEffect(() => {
fetch('/api/data')
}, []);
16
2.5.1.2 COMPONENTWILLUNMOUNT
useEffect(() => {
return () => {
clearInterval(timer);
};
}, []);
Forms are essential for capturing user input. React manages form inputs through
controlled components, where the state of the input is linked to React's state.
In controlled components, input fields derive their values from React state:
e.preventDefault();
};
return (
<form onSubmit={handleSubmit}>
17
<input
type="text"
value={name}
/>
<button type="submit">Submit</button>
</form>
);
2.5.2.2 VALIDATION
React allows form validation either manually or with libraries like Formik or
React Hook Form:
e.preventDefault();
alert('Name is required');
} else {
};
18
2.6 ADVANCED REACT CONCEPTS
Rendering lists dynamically is common in React, and using unique keys ensures
efficient updates:
The Context API is used for state management in applications to avoid prop
drilling:
return (
19
<UserContext.Provider value={user}>
<Dashboard />
</UserContext.Provider>
);
};
return (
<Router>
<Switch>
</Switch>
</Router>
);
20
2.7.1.2 NAVIGATION
Styling in React can be done using various methods, including CSS, inline styles,
CSS Modules, and styled-components.
2.7.2.2 STYLED-COMPONENTS
background-color: blue;
color: white;
padding: 10px;
`;
<Button>Click Me</Button>;
21
2.7.3 ADVANCED FEATURES
React Context API and external libraries like Redux can manage global states
efficiently. Context API example:
<ThemeContext.Provider value="dark">
<ThemedComponent />
</ThemeContext.Provider>
);
Using React.lazy and Suspense, components are loaded only when needed:
<Suspense fallback={<div>Loading...</div>}>
<LazyComponent />
</Suspense>;
2.7.3.3 AUTHENTICATION
22
.then((userCredential) => console.log('Signed in:', userCredential))
23
CHAPTER 3
MY PROPOSAL
3.1 INTRODUCTION
This report specifically details the phased development of the Quizzes Feature,
a core component of EduHub Lite. The Quizzes Feature enables users to attempt
quizzes, answer multiple-choice questions, and receive instant feedback and
automated scoring. It aims to enhance learning through interactive assessments,
empowering students to evaluate their progress in a structured and engaging
manner.
1. Navigation:
24
2. Page Management:
4. Quizzes Logic:
25
3.4 PROJECT SETUP
ENVIRONMENT SETUP:
26
3.5 PLANNING AND DEVELOPMENT
Objective:
Create a reusable, responsive navigation bar to link to all primary pages of the
application.
Features:
Steps:
3. Add active class styling for the currently selected route using
useLocation.
Code Structure:
• File: Navbar.jsx
• Styling: Navbar.css
Code: Navbar.jsx
import './Navbar.css';
return (
<nav className="navbar">
EduHub
</Link>
<div className="navbar-links">
</div>
</div>
</nav>
);
};
28
3.5.2 DASHBOARD PAGE
Objective:
Provide users with a summary of their activity, including tasks, courses, and
quizzes progress.
Features:
Steps:
2. Fetch user activity data (mock data for now, API in the future).
Code Structure:
• File: Dashboard.jsx
• Styling: Dashboard.css
Code : Dashboard.jsx
import './Dashboard.css';
const widgets = [
return (
<div className="dashboard">
<div className="dashboard-widgets">
{widgets.map((widget) => (
<h3>{widget.title}</h3>
<p>{widget.value}</p>
</div>
))}
</div>
</div>
);
};
CSS: Dashboard.css
.dashboard {
padding: 20px;
.dashboard-title {
30
font-size: 2rem;
margin-bottom: 20px;
.dashboard-widgets {
display: flex;
justify-content: space-around;
gap: 20px;
.widget {
background-color: white;
padding: 20px;
border-radius: 8px;
text-align: center;
Objective:
List all available courses for the user with options to view course details.
Features:
31
Steps:
3. Add a "View Details" button for each course linking to the course detail
page.
Code Structure:
• File: Courses.jsx
• Styling: Courses.css
Code: Courses.jsx
import './Courses.css';
const courses = [
];
return (
<div className="courses">
<h1>Courses</h1>
<div className="course-list">
{courses.map((course) => (
<p>{course.description}</p>
<button>View Details</button>
</div>
))}
</div>
</div>
);
};
Objective:
Provide a task management interface where users can view, add, and mark tasks
as complete.
Features:
Steps:
• File: Tasks.jsx
• Styling: Tasks.css
Code: Tasks.jsx
import './Tasks.css';
]);
if (newTask.trim()) {
setNewTask('');
};
34
setTasks(tasks.map(task => task.id === id ? { ...task,
completed: !task.completed } : task));
};
return (
<div className="tasks">
<h1>Tasks</h1>
<div className="task-list">
{tasks.map(task => (
<input
type="checkbox"
checked={task.completed}
/>
</div>
))}
</div>
<input
type="text"
value={newTask}
35
onChange={(e) => setNewTask(e.target.value)}
placeholder="New Task"
/>
</div>
);
};
Objective:
List quizzes for the user to attempt and provide interactive quiz-taking
functionality.
Features:
Steps:
36
Code Structure:
• Styling: Quizzes.css
Code: Quizzes.jsx
import '../styles/Quizzes.css';
const quizzes = [
id: 1,
questions: [
],
},
id: 2,
questions: [
37
{ question: 'What is JSX?', options: ['JavaScript XML', 'JSON', 'JavaScript
Syntax', 'None'], correct: 0 },
],
},
id: 3,
questions: [
{ question: 'What does HTML stand for?', options: ['Hyperlinks and Text
Markup Language', 'Home Tool Markup Language', 'Hyper Text Markup
Language', 'None'], correct: 2 },
{ question: 'Which tag is used for the largest heading?', options: ['<h1>',
'<h6>', '<heading>', '<header>'], correct: 0 },
],
},
id: 4,
questions: [{ question: 'What does CSS stand for?', options: ['Colorful Style
Sheets', 'Cascading Style Sheets', 'Computer Style Sheets', 'Creative Style
Sheets'], correct: 1 },
38
{ question: 'Which property is used to change the background color?', options:
['bgcolor', 'color', 'background-color', 'background'], correct: 2 },
],
},
id: 5,
questions: [
{ question: 'What is the square root of 64?', options: ['6', '7', '8', '9'], correct:
2 },
],
},
];
setAnswers({});
39
setScore(null);
};
};
let calculatedScore = 0;
activeQuiz.questions.forEach((q, i) => {
calculatedScore += 1;
});
setScore(calculatedScore);
};
return (
<div className="quizzes">
{!activeQuiz ? (
<>
<ul className="quiz-list">
{quizzes.map((quiz) => (
40
<li key={quiz.id} className="quiz-item">
<h3>{quiz.title}</h3>
</li>
))}
</ul>
</>
):(
<>
<h1 className="quiz-title">{activeQuiz.title}</h1>
<div className="quiz-questions">
<p>{q.question}</p>
<div className="quiz-options">
{q.options.map((option, i) => (
<label key={i}>
<input
type="radio"
name={`question-${index}`}
value={i}
41
checked={answers[index] === i}
/>
{option}
</label>
))}
</div>
</div>
))}
</div>
Submit Quiz
</button>
<div className="quiz-result">
</div>
)}
</>
)}
42
</div>
);
};
3.5.7 TIMELINE
43
3.6 OUTPUT AND DISCUSSION
3.6.1 OUTPUT
44
• Courses: Displays available courses with descriptions.
45
Fig 3.7 Tasks
Achievements:
Challenges:
47
CHAPTER 4
Introduce a secure login system with role-based access (e.g., students and
administrators). Each user will have a personalized profile with their activity
history and performance analytics.
Benefits:
Benefits:
Add detailed course pages where educators can upload content, manage
modules, and provide assignments. Students can track their progress and interact
with course materials.
48
Benefits:
Benefits:
Benefits:
49