This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
README : To install moltin https://moltin.com/quick-start/swift/ | |
import moltin | |
class MoltinManager : NSObject { | |
let moltin: Moltin = Moltin(withClientID: AppDelegate.moltinId) | |
var categories: [moltin.Category] = [] | |
var products: [Product] = [] | |
var product: Product? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// moltin SDK setup | |
const moltin = require('@moltin/sdk'); | |
const MoltinSite = moltin.gateway({ | |
client_id: process.env.CLIENT_ID_SITE, | |
client_secret: process.env.CLIENT_SECRET_SITE | |
}); | |
exports.formatOrders = function(orders, items) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.omgandroid; | |
import android.content.Context; | |
import android.content.SharedPreferences; | |
import android.util.Log; | |
import com.loopj.android.http.AsyncHttpClient; | |
import com.loopj.android.http.JsonHttpResponseHandler; | |
import com.loopj.android.http.RequestParams; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.content.Context; | |
import android.content.SharedPreferences; | |
import android.util.Log; | |
import com.loopj.android.http.AsyncHttpClient; | |
import com.loopj.android.http.JsonHttpResponseHandler; | |
import com.loopj.android.http.RequestParams; | |
import org.json.JSONException; | |
import org.json.JSONObject; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<link rel="stylesheet" type="text/css" href="cart.css"> | |
<!-- <script src="cart.js"> --> | |
</script> | |
<script src="https://unpkg.com/@moltin/sdk"></script> | |
<!-- | |
quick install https://developers.moltin.com/your-first-api-request |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import _ from 'lodash' | |
import React, { Component } from 'react' | |
import { Search, Grid, Header, Segment } from 'semantic-ui-react' | |
import { getProducts } from '../lib/moltin' | |
export default class SearchExampleStandard extends Component { | |
constructor(props) { | |
super() | |
this.state = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Link from 'next/link' | |
import Head from 'next/head' | |
import Router from 'next/router' | |
import NProgress from 'nprogress' | |
import { Menu, Container, Image, Icon } from 'semantic-ui-react' | |
import Search from './Search' | |
Router.onRouteChangeStart = url => NProgress.start() | |
Router.onRouteChangeComplete = () => NProgress.done() | |
Router.onRouteChangeError = () => NProgress.done() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"data":[ | |
{ | |
"type":"product", | |
"id":"6fe08392-f483-4763-98d8-bb37e42b6356", | |
"name":"Flight Deposit", | |
"slug":"flight-deposit", | |
"sku":"fdp", | |
"manage_stock":false, | |
"description":"Flight Deposit", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from "react"; | |
import PropTypes from "prop-types"; | |
import Link from "next/link"; | |
import Title from "./styles/Title"; | |
import ItemStyles from "./styles/ItemStyles"; | |
import PriceTag from "./styles/PriceTag"; | |
import formatMoney from "../lib/formatMoney"; | |
import AddToCart from "./AddToCart"; | |
import styled from "styled-components"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"breadcrumbs": [ | |
{ | |
"url": "https://headless.mybigcommerce.com/", | |
"name": "Home" | |
} | |
], | |
"blog": { | |
"name": "Blog", | |
"url": "/blog/", |
OlderNewer