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
//Your custom function. API key provided after you "Publish" your version of the function | |
blockspring.runParsed("YOURAPIKEYHERE", { | |
//Can either be POST or GET, depending on if you want to read or write | |
'type': 'POST', | |
// This is your internal function name. | |
// Must match the key from urlHash so you can access the appropriate sheet | |
'name': 'postEntry', | |
// Values if it is a post. If a get, should be Query just like the normal examples. | |
"values": allData}, | |
function(res){ |
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
var userData= getGithubData('testuser'); | |
function getGithubData(username) { | |
$.get('https://api.github.com/users/' +username, function(user){ | |
var key= user.data.info.name | |
$.get('https://api.github.com/users/' +key+ '/repos&per_page=100', function(user2){ | |
var followers= user2.data.info.followers | |
storeFollowers(followers, function(){ | |
console.log('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
var amount= 1000; | |
getCasinoTokens(1000) | |
.then(function(tokens){ | |
return playBlackjack(tokens*0.3) | |
}) | |
.then(function(moreTokens){ | |
return playRoulette(moreTokens*0.05) | |
}) | |
.then(function(evenMoreTokens){ |
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
var amount= 1000; | |
getCasinoTokens(amount) | |
.then(blackjackTable) | |
.then(rouletteTable) | |
.then(pokerTable) | |
.catch(function(err){ | |
complainToManager(err) | |
startDrinking() | |
}) |
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
var amount= 1000; | |
getCasinoTokens(amount, function(tokens, err){ | |
if (err) complainToManager(err) | |
playBlackjack(tokens*0.3, function(moreTokens, err){ | |
if (err) complainToManager(err) | |
playRoulette(moreTokens*0.05, function(evenMoreTokens, err) { | |
if (err) complainToManager(err) | |
playPoker(evenMoreTokens*0.5, function(finalTokens, err){ | |
if (err) complainToManager(err) |
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
function packBox(item){ | |
console.log('Put ' +item+ ' in the box'); | |
function addressPackage(address){ | |
console.log('Addressed the box to ' +address+' and ready to send the '+item+' gift'); | |
} | |
return addressPackage; | |
} |
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
var brotherGift = packBox('jersey') | |
var motherGift = packBox('iTunesCard') | |
var fatherGift = packBox('golfclubs') | |
var sisterGift = packBox('lacrossestick') | |
brotherGift('123 Main Street, Anywhere USA 01234') | |
//Put jersey in the box | |
// Addressed the box to 123 Main Street, Anywhere USA 01234 and ready to send the jersey gift | |
motherGift('123 High Street, Los Angeles USA 01234') | |
//Put iTunesCard in the box |
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
<body> | |
<div class='fullSundae'> | |
<div class='cherry'></div> | |
<div class='whippedCream'></div> | |
<div class='iceCreamScoop'></div> | |
<div class='iceCreamScoop'></div> | |
<div class='glass'> | |
<div class='iceCreamScoop'></div> | |
<div class='iceCreamScoop'></div> | |
<div class='iceCreamScoop'></div> |
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
.fullSundae{ | |
height:500px; | |
position:static; | |
} | |
.fullSundae > .iceCreamScoop{ | |
height:100px; | |
} | |
.glass{ |
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
var vadersEmpire = React.createClass({ | |
getInitialState: function() { | |
return { | |
rebelLocation: '' | |
}; | |
}, | |
render: function() { | |
return ( | |
<div> |