James Sugrue [asked][1], "@GitHubAPI is there a way to find the number of stars for a given repository?"
$ curl -ni "https://api.github.com/search/repositories?q=more+useful+keyboard" -H 'Accept: application/vnd.github.preview'
{
var traverse = function(o, fn) { | |
for (var i in o) { | |
fn.apply(this,[i,o[i]]); | |
if (o[i] !== null && typeof(o[i])=="object") { | |
traverse(o[i], fn); | |
} | |
} | |
} | |
// usage |
Format: YYYY-MM-DDTHH:mm:ss.sssZ | |
Date: ^\d{4}(-\d{2}){0,2}$ | |
Time: ^\d{2}(:\d{2}(:\d{2}(\.\d+)?)?)?$ | |
Time with optional timezone: ^\d{2}(:\d{2}(:\d{2}(\.\d+)?)?)?(Z|[\+|-]\d{2}:\d{2})?$ | |
Date and/or time with optional timezone: | |
(^\d{4}(-\d{2}){0,2})?((^|T)\d{2}(:\d{2}(:\d{2}(\.\d+)?)?)?(Z|[\+|-]\d{2}:\d{2})?)?$ | |
#add 'node_modules' to .gitignore file | |
git rm -r --cached node_modules | |
git commit -m 'Remove the now ignored directory node_modules' | |
git push origin <branch-name> |
var pdf = new jsPDF(); | |
pdf.text(0, 0, 'Hello World!'); | |
var pdfBase64 = pdf.output('datauristring'); | |
window.plugin.email.open({ | |
to: ['[email protected]'], | |
subject: 'New PDF!', | |
body: 'Hi there, here is that new PDF you wanted!', | |
isHTML: false, | |
attachments: [pdfBase64] |
/** | |
* Dojo AMD Google Maps Loader Plugin | |
*/ | |
define([ | |
"dojo/_base/kernel", | |
"dojo/topic" | |
], function (kernel, topic) { | |
var w = kernel.global; | |
var cb ="_googleApiLoadCallback"; |
{ | |
"AL": "Alabama", | |
"AK": "Alaska", | |
"AS": "American Samoa", | |
"AZ": "Arizona", | |
"AR": "Arkansas", | |
"CA": "California", | |
"CO": "Colorado", | |
"CT": "Connecticut", | |
"DE": "Delaware", |
import json | |
from functools import wraps | |
from flask import redirect, request, current_app | |
def support_jsonp(f): | |
"""Wraps JSONified output for JSONP""" | |
@wraps(f) | |
def decorated_function(*args, **kwargs): | |
callback = request.args.get('callback', False) | |
if callback: |