These rules are adopted from the AngularJS commit conventions.
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
/* | |
Native Arrays are not great structures for cellular automata. | |
Non-empty, circular, doubly-linked lists would be ideal... | |
but all we really need to do is write a comonadic-like interface | |
such that it _pretends_ that the array is circular, and can thus | |
pass the exfn below a sort of "local" slice of an Array as if it were circular. | |
So you can mostly ignore the implementation mess below | |
*/ | |
Array.prototype.extendNear = function(exfn){ | |
const len = this.length; |
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
<?php | |
use Zend\Expressive\AppFactory; | |
use Firebase\JWT\JWT; | |
use Slim\Middleware\JwtAuthentication; | |
chdir(dirname(__DIR__)); | |
require "vendor/autoload.php"; | |
$app = AppFactory::create(); |
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
namespace :deploy do | |
reset = "\033[0m" | |
success = "\033[32m" # Green | |
failure = "\033[31m" # Bright Red | |
task :completed do | |
puts "#{success}" | |
puts "*" * 40 | |
puts "SUCCESS" | |
puts "*" * 40 |
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 lang="en"> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<title>SoundCloud OAuth 2 User Agent Authentication Flow Demo</title> | |
<script type="text/javascript" charset="utf-8" src="javascript/jquery-1.4.2.js"></script> | |
<script type="text/javascript" charset="utf-8"> | |
$(function () { | |
var extractToken = function(hash) { |