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
{ | |
"category": "s_exp", | |
"components": [ | |
"+" | |
], | |
"implementation": "function(){return (function (cdr){return cdr.reduce(function(a, b) {return a + b}, 0);});}" | |
} |
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
{ | |
"category": "example widgets", | |
"components": [ | |
"paint a picture" | |
], | |
"url": "http://ngokevin.github.com/gogh/" | |
} |
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
{ | |
"category": "s_exp", | |
"components": [ | |
{"regex": "\\(\\s*\\)"} | |
], | |
"implementation": "function () {return [];}", | |
"asyncImpl": "callback([])" | |
} |
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
$.getJSON("http://query.yahooapis.com/v1/public/yql/", { | |
"env":"http://github.com/spier/yql_worldbank/raw/master/alltables.env", | |
"q":'SELECT * FROM worldbank.data(0,100) WHERE indicator_id = "SP.POP.TOTL" AND country_id = "GHA" AND from_year = 1980 AND to_year = 1985', | |
"format": "json", | |
"jsonp" : "?" | |
}, function(res) { | |
console.log(res.query.results.data); | |
}); |
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
{ | |
"category": "main", | |
"components": [ | |
"population of ", {"regex":"[\\w\\s]{2,20}", "tag" : "country"}, " since ", {"regex":"\\d{4}", "tag" : "from_year"} | |
], | |
"url": "http://nathanathan.github.com/LanguageWidgets/plotWidget.html" | |
} |
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> | |
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en"> <![endif]--> | |
<!--[if IE 7]> <html class="no-js ie7 oldie" lang="en"> <![endif]--> | |
<!--[if IE 8]> <html class="no-js ie8 oldie" lang="en"> <![endif]--> | |
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]--> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | |
<title>Widget</title> | |
<base target="_blank" /> |
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
/* Requires underscore.js */ | |
var SERVER_URL = "http://ec2-50-16-84-43.compute-1.amazonaws.com/xlsform/2/json_workbook/"; | |
/* | |
//The ideal approach would be to send the workbook as an xlsx blob | |
//and process it the same way as user uploads. | |
//Unfortunately I can't figure out how to generate such a blob. | |
function sendBlob() { | |
var file = DocsList.getFileById(SpreadsheetApp.getActiveSpreadsheet().getId()); |
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
{ | |
"category": "main", | |
"components": [ | |
"google", {"regex":"\\s*"}, {"regex":".*"} | |
] | |
} |
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
{ | |
"category": "main", | |
"components": [ | |
"recent queries" | |
] | |
} |
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> | |
<meta charset="utf-8"> | |
<style> | |
body { | |
font: 10px sans-serif; | |
} | |
</style> | |
<body> |