Full Stack Camp
144 subscribers
8 photos
16 files
89 links
Fullstack Camp | Learn. Build. Launch.
Welcome to the ultimate tech adventure!
Join us for a hands-on journey through HTML, CSS, JavaScript, React, Node.js, Express & MongoDB β€” all in one place.
Download Telegram
πŸ’₯Week 7 Day 7 challenges

🧩 Challenge 1: Modular Blog API

πŸ‘‰ Build a small blog API using Express Router.
Requirements:
Create routes folder
πŸ—‚οΈ posts.js
πŸ—‚οΈ authors.js
Each file should export a router
Main app.js must use them like:
app.use("/posts", postsRouter); app.use("/authors", authorsRouter);
Endpoints to include (just dummy responses):
βœ” /posts/ β†’ return list of posts
βœ” /posts/:id β†’ return a single post
βœ” /authors/ β†’ return list of authors
βœ” /authors/:id β†’ return author details
Add middleware:
Use morgan for request logging
Use uuid to generate post IDs

🧩 Challenge 2: Notes API with Router + File Storage

πŸ‘‰ Build a simple Notes API, split into modules:
πŸ“ /routes/notes.js
πŸ“ /data/notes.json
Endpoints:
βœ” GET /notes β†’ return all notes
βœ” POST /notes β†’ add a new note
βœ” DELETE /notes/:id β†’ delete a note
Requirements:
βž™Use uuid to generate IDs
βž™Use fs to read/write JSON file
βž™Use express.json()` middleware
Extra:
Add CORS package so any frontend can access it

🧩 Challenge 3: Student Manager

πŸ‘‰ Create Student Manager with:
πŸ“ /routes/students.js
πŸ“ /data/students.json
Endpoints:
βœ” GET /students
βœ” POST /students
βœ” GET /students/:id
βœ” DELETE /students/:id
Use packages:
dotenv β†’ load PORT from .env
nodemon β†’ auto restart
.env example:
PORT=4000

🎁 Optional Bonus
Add routes with Router-level middleware:
Example:
router.use((req, res, next) => {
  console.log("Students Router  middleware running");
next(); });


When you are done:
πŸ’₯share your solutions in the group,
πŸ’₯invite a friend,
      and as always β€”

πŸ’₯stay well, stay curious, and stay coding ✌️
Full Stack Camp pinned Β«πŸ‘‹ Welcome to Fullstack Summer Camp 2025! Learn. Build. Launch. Hey campers! 🌞 This is your one-stop space to master fullstack web development from scratch β€” right here on Telegram. Over the next 12 weeks, we’ll dive deep into: 🌐 Frontend: HTML, CSS, JavaScript…»
Full Stack Camp pinned Β«Week 1 Day 1  πŸ’‘ What Is Coding? How It Works, Why It Matters, and How You Can Start 🌞 Welcome welcome welcome to Fullstack Summer Camp!  αˆ°αˆ‹αˆαˆαˆαˆ πŸ‘‹ Today is Day 1 of our fullstack development journey. Whether you're here because you're curious, bored, or…»
Express review questions
4️⃣How do you read route parameters in Express?
Anonymous Quiz
0%
a) req.query
50%
b) req.params
50%
c) req.body
0%
d) req.route
5️⃣Which request URL matches this route? app.get("/products/:id")
Anonymous Quiz
67%
a) /products?id=5
33%
b) /products/5
0%
c) /product/5
0%
d) /products?id=:id
6️⃣What happens if you send two responses in one request?
Anonymous Quiz
0%
a) Express ignores the second one
50%
b) Server crashes
50%
c) Browser handles it
0%
d) Express throws an error
7️⃣Which package helps log HTTP requests?
Anonymous Quiz
100%
a) cors
0%
b) dotenv
0%
c) morgan
0%
d) uuid
9️⃣Where should sensitive data like API keys be stored?
Anonymous Quiz
0%
a) In JavaScript files
0%
b) In package.json
100%
c) In .env file
0%
d) In routes
πŸ”ŸHow do you set an HTTP status code in Express?
Anonymous Quiz
0%
a) res.send(404)
50%
b) res.status(404).send()
50%
c) req.status(404)
0%
d) res.code(404)
1️⃣1️⃣Which situation will cause an Express app to hang (never respond)?
Anonymous Quiz
33%
a) Sending res.json()
67%
b) Forgetting to call next() in middleware
0%
c) Using app.get()
0%
d) Forgetting express.json()
1️⃣2️⃣ What is a common mistake when using res.sendFile()?
Anonymous Quiz
0%
a) Sending JSON
100%
b) Forgetting absolute path or __dirname
0%
c) Using HTTP instead of HTTPS
0%
d) Missing headers
1️⃣3️⃣ What happens if two routes match the same request?
Anonymous Quiz
50%
a) Express throws an error
0%
b) Both routes run
50%
c) The first matching route runs
0%
d) The last route runs
1️⃣5️⃣ What is the biggest downside of file-based storage (fs) APIs?
Anonymous Quiz
0%
a) Too secure
50%
b) Hard to read
50%
c) Not scalable & risk of data corruption
0%
d) Slow internet
1️⃣6️⃣ Why is fs.readFileSync() dangerous in servers?
Anonymous Quiz
0%
a) It uses callbacks
50%
b) It blocks the event loop
50%
c) It deletes files
0%
d) It crashes Express
1️⃣7️⃣ What best describes Express itself?
Anonymous Quiz
0%
a) A programming language
50%
b) A database
0%
c) A frontend library
50%
d) A Node.js web framework