Global

Methods

addToCart(product, quantityopt)

Adds a product to the cart and notifies the user.

Parameters:
Name Type Attributes Default Description
product Object

The product object to add.

quantity number <optional>
1

Quantity to add.

Source:

createMasterGraph(products) → {Graph}

Factory function that creates and populates the master graph of flower compatibility.

Parameters:
Name Type Description
products Array.<Object>

Array of all shop products (used to get vertex names).

Source:
Returns:

The fully initialized Graph instance.

Type
Graph

updateCartCount()

Exports function to update the cart count displayed in the header UI.

Source: