Skip to content
This repository was archived by the owner on Sep 25, 2018. It is now read-only.
sdn90Public archive

About

Promise based client for Shopify Ajax API

Resources

Stars

2 stars

Watchers

1 watching

Forks

Latest commit

 

History

5 Commits

Folders and files

Repository files navigation

Preamble Ajax

You need to bring your own Promise polyfill.

Usage

getProduct(handle)

Arguments

  1. handle (String): The handle of the product

Returns

(Object): JSON representation of the product

Example

import { getProduct } from 'preamble-ajax';

getProduct('black-t-shirt');
// → { id: 1, handle: 'black-t-shirt', ... }

addCart(options)

Arguments

  1. options (Object)

Returns

(Object): JSON representation of the product added

Example

import { addCart } from 'preamble-ajax';

addCart({
  id: 1234567,
  quantity: 1,
  properties: {
    'Foo': 'Bar'
  }
});

About

Promise based client for Shopify Ajax API

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages