Giter Site home page Giter Site logo

ramirorichmand / lab22_09.03.23_thebakery_react Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 179 KB

Started building an app that I'll develop further as I learn more about React. The user will be able to see a range of cake recipes and be able to add their own, but for now I will display three pre-selected recipes on the screen.

HTML 23.71% CSS 12.18% JavaScript 64.11%

lab22_09.03.23_thebakery_react's Introduction

09/03/23 Lab The Bakery ๐Ÿ‘จโ€๐Ÿณ๐Ÿง

Started building an app that I'll develop further into as I learn more about React. Ultimately the user will be able to see a range of cake recipes and be able to add their own, but for now I will display three pre-selected recipes on the screen.

MVP ๐ŸŽฏ

The details of the cakes are below:

// Victora Sponge
{
	cakeName: "Victoria Sponge",
   	ingredients: [
   		"eggs",
      	"butter",
      	"sugar",
      	"self-raising flour",
      	"baking powder",
      	"milk"
  	],
  	price: 5
   	rating: 5
}

// Tea Loaf
{
 	cakeName: "Tea Loaf",
   	ingredients: [
   		"eggs",
      	"oil",
      	"dried fruit",
      	"sugar",
      	"self-raising flour",
      	"strong tea",
  	],
  	price: 2,
  	rating: 3
}

// Carrot Cake
{
 	cakeName: "Carrot Cake",
   	ingredients: [
    	"carrots",
      	"walnuts",
      	"oil",
      	"cream cheese",
      	"flour",
      	"sugar",
   	],
   	price: 8,
   	rating: 5
} 
  • Each cake has a name, a list of ingredients, a price and a rating. The app should also include the average rating of all cakes. Draw a wireframe diagram to show how this information could be displayed on the page.
  • Draw a component diagram and consider where the state should be and what props need to be passed to which component.
  • Build a React app according to your design

Extensions ๐Ÿ“š

  • Add CSS to your app.
  • Add a piece of state to track the total value of the cakes sold. Add a "sell cake" button to each cake - when the button is clicked the total sale value should update appropriately.
  • There are two ways we can go about listing the ingredients. One would be to individually access each element in the array (cake.ingredients[0], etc.) but that's not very dynamic - what happens if we get a cake with only five ingredients? If you haven't already, try to build out the ingredient list dynamically.

lab22_09.03.23_thebakery_react's People

Contributors

ramirorichmand avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.