Skip to content

Instantly share code, notes, and snippets.

@LiviaSarban
Created November 13, 2017 02:49
Show Gist options
  • Save LiviaSarban/bc3ccd9e8cf668994ee9b30352b0ea4c to your computer and use it in GitHub Desktop.
Save LiviaSarban/bc3ccd9e8cf668994ee9b30352b0ea4c to your computer and use it in GitHub Desktop.
Product Listing // source https://jsbin.com/lafawov
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Product Listing</title>
</head>
<body>
Product Type: ketchup
Brand:
Price:
URL:
Buy again?: Yes/No
if (repeatPurchase === true){
Add to cart:
var purchaseURL
}
</body>
</html>
Data Structure:
var product {
"productType":"ketchup",
"brand":"",
"productUrl":"....",
"repeatPurchase":true,
"purchaseUrl":"",
"lastPurchase": .....
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment