Skip to content

mattjjohnson007/js-data

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JS Data Assignment

Assignment Goals:

  • gain a deeper appreciation for how JavaScript variables are created scoped
  • create a JSON Data to represent an object
  • build a objects from JSON data
  • use DOM methods to add HTML to display the object

GitHub Repository

https://github.com/htc-ccis2591/js-data/

You’ll want to begin each assignment by forking the repository and cloning it locally. When you are done, you’ll push to GitHub and submit a pull request.

Moonflower Feature

A new section was added to the HTML to feature an item from the menu.

Put the Data into JSON

Use the information below to write JSON to hold the featured items for the week. Each featured item has a name, image, and description. There are two featured items this week, but there may be more later, so they should be in an array.

Item 1:

  • name: "Hazelnut Cappuccino",
  • image: "images/cappuccino.jpg",
  • description: "A warm, soothing cappuccino with a touch of hazelnut to warm you as the weather turns."

Item 2:

  • name: "Chocolate Cake",
  • image: "images/choc-cake.jpg",
  • description: "Our chocolate cake is rich, moist, and dark. More chocolate to love."

Use the Data to Show the Features

Use your JSON data to build and add HTML to show the two featured items in the “featured-items” div. Create and add the HTML to the page using JavaScript. The code that you write should be able to add any number of featured items to the page.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 41.8%
  • HTML 40.5%
  • CSS 17.7%