Tutorials › JavaScript Programming › Course project
Peer-graded course project

Interactive Price List for a Shop

Pass mark 70% Review 3 classmates 5-part rubric · 20 points
  1. 1
    Submit your workText, a link or a file
  2. 2
    Review 3 classmatesUnlocks after you submit
  3. 3
    Get your gradeAverage of peer scores
Sign in to take part.Sign in or create a free account, enroll in this course and submit your project.

The situation

Achieng owns "Achieng's Cereals", a made-up shop in Kisii that sells maize, beans, rice and millet. Customers keep asking the price of things on WhatsApp. She wants a simple web page where people can search the products, filter by price and see how many items match. You will build it in plain JavaScript as a portfolio piece, using made-up products and example prices.

Note: Use made-up details only. Do not put a real phone number, email, address, password or API key in your code or page. Write "07XX XXX XXX" if you add a contact line.

What you will produce

  1. A working page (HTML, CSS and JavaScript in one file, or three files) with:
  • an array of 8–10 product objects, each with at least a name, price (example KES figures) and category,
  • a list of products shown on the page by JavaScript,
  • a text box that filters products as the user types,
  • a second control (a "max price" box, a category dropdown or an "in stock only" tick-box),
  • a line saying how many products are showing, for example "4 products found",
  • a clear message when nothing matches.
  1. A bonus feature of your choice (optional but recommended), such as saving the last search with localStorage or sorting by price.
  2. A short explanation – 100–150 words: how the filtering works, which array method you used (filter, map, reduce or others), one bug you fixed, and one thing you would add next.

Steps

  1. Re-read the lessons on arrays and objects, the to-do list app and the product catalogue project.
  2. Write the product array first and print it to the console to check it.
  3. Show the products on the page, then add the search box.
  4. Add the second filter and the count line.
  5. Test: empty search, a word with capital letters, a word that matches nothing.
  6. Put your work on CodePen or GitHub and write your explanation.

What to submit

  • Your code pasted in the text box and/or a public CodePen or GitHub (Pages) link.
  • Your short explanation in the text box.
  • Optional: a screenshot (PNG or JPG, max 5 MB).

Tips

  • Change the text to lowercase before comparing, so "Rice" and "rice" both match.
  • Keep one function to draw the list and call it after every change.
  • Use comments so a peer can follow your code.

How it's graded

PartWhat good work looks likePoints
Data and displayAn array of 8–10 objects is rendered correctly on the page4
Search and filtersSearch plus a second filter both work and can be combined6
Feedback to userCount line and a no-results message appear correctly3
Code quality and explanationReadable names and comments, and an accurate 100–150 word explanation5
Privacy and presentationMade-up details only, and the link or code opens and runs2
Total – you pass at 70% (14 of 20 points)20