BeginnerCoder

Lesson 25 — Ultimate: mini dashboard

Boss level: summary cards

Put it all together: derive several stats from one dataset and render each as a small card with a reusable Stat component. The data lives in one array; every number on screen is computed from it, and the cards are produced with map from a list of [label, value] pairs.

Note: Next.js pages are React components, so this preview runs your code with plain React in the browser. Next.js-only features (the file router, server rendering, data fetching on the server) are not running here — where a lesson needs them, it shows a small simulation instead.

Why it matters: this is a real dashboard screen — and the same pattern scales to dozens of stats.

Want it another way?
Task

Compute pending, and render one <Stat> per entry of stats with map (label and value props).

Test your knowledge

A quick 3-question quiz on this lesson — instant feedback.

Enjoying this lesson? Share it.

Keep going with Next.js Foundations

Ready for more? Optional paid resources that pick up where this lesson leaves off.

Some links on this page are affiliate links: we may earn a commission at no extra cost to you. As an Amazon Associate I earn from qualifying purchases.