Live demo https://jsfiddle.net/Kolosovsky/tdqv6pk2/
let points = [
{ x: 125, y: 50 },
{ x: 250, y: 65 },| const https = require("https") | |
| const fetch = require("isomorphic-fetch") | |
| const Account = require("./models/account") | |
| const authenticated = require("./lib/auth") | |
| exports.handler = authenticated(async (event, context) => { | |
| const { id: shopId, shopifyToken } = context.account | |
| try { | |
| const resp = await fetch(`https://${shopId}/admin/api/2019-07/graphql.json`, { |
Live demo https://jsfiddle.net/Kolosovsky/tdqv6pk2/
let points = [
{ x: 125, y: 50 },
{ x: 250, y: 65 },| // It is important to declare your variables. | |
| (function() { | |
| var foo = 'Hello, world!'; | |
| print(foo); //=> Hello, world! | |
| })(); | |
| // Because if you don't, the become global variables. | |
| (function() { |