API Reference
@frontend-sdk/justuno - v0.25.1
Interfaces
Functions
useJustuno
▸ Const
useJustuno(juAccountNumber
): void
Parameters
Name | Type |
---|---|
juAccountNumber | string |
Returns
void
useJustunoConversions
▸ useJustunoConversions(): JustunoConversionActions
Returns
Interface: Cart
Properties
currency
• Optional
Readonly
currency: string
shipping
• Optional
Readonly
shipping: number
subtotal
• Optional
Readonly
subtotal: number
tax
• Optional
Readonly
tax: number
total
• Readonly
total: number
Interface: CartItem
Properties
color
• Optional
Readonly
color: string
name
• Optional
Readonly
name: string
price
• Optional
Readonly
price: number
productid
• Readonly
productid: string
quantity
• Readonly
quantity: number
size
• Optional
Readonly
size: string
sku
• Optional
Readonly
sku: string
variationid
• Optional
Readonly
variationid: string
Interface: JustunoConversionActions
Properties
addCartItem
• Readonly
addCartItem: (cartItem
: CartItem) => void
Type declaration
▸ (cartItem
): void
Add a cart item to the cart.
Parameters
Name | Type |
---|---|
cartItem | CartItem |
Returns
void
addCustomData
• Readonly
addCustomData: (key
: string
, value
: string
) => void
Type declaration
▸ (key
, value
): void
Add arbitrary custom data to the JustUno context that can be used to
customize promotions.
Parameters
Name | Type |
---|---|
key | string |
value | string |
Returns
void
trackConversion
• Readonly
trackConversion: (orderId
: string
, order
: Cart, orderItems
: CartItem[]) => void
Type declaration
▸ (orderId
, order
, orderItems
): void
Given a cart and all of the cart items, performs all of the conversion
calls for all items.
Parameters
Returns
void
trackOrder
• Readonly
trackOrder: (orderId
: string
, order
: Cart) => void
Type declaration
▸ (orderId
, order
): void
Track a conversion for the specified orderId and order.
Parameters
Name | Type |
---|---|
orderId | string |
order | Cart |
Returns
void
trackOrderItem
• Readonly
trackOrderItem: (orderItem
: CartItem) => void
Type declaration
▸ (orderItem
): void
Track a conversion for the specified orderItem.
Parameters
Name | Type |
---|---|
orderItem | CartItem |
Returns
void
updateCart
• Readonly
updateCart: (cart
: Cart) => void
Type declaration
▸ (cart
): void
Update cart information.
Parameters
Name | Type |
---|---|
cart | Cart |
Returns
void
updateCartItems
• Readonly
updateCartItems: (cartItems
: CartItem[]) => void
Type declaration
▸ (cartItems
): void
Update all of the items in the cart.
Parameters
Name | Type |
---|---|
cartItems | CartItem[] |
Returns
void
Updated over 1 year ago