Skip to content

Instantly share code, notes, and snippets.

View yanbab's full-sized avatar

yanbab

  • Nantes, France
View GitHub Profile
@robhurring
robhurring / README.md
Last active December 20, 2015 04:49
Angular weather service using openweathermap.org -- not fully tested. (uses gist: https://gist.github.com/robhurring/6074128)
@twilson63
twilson63 / app.js
Created September 5, 2012 02:17
AngularJS Contact Form Example
function ContactCtrl($scope, $http) {
$scope.success = false;
$scope.httpError = false;
$scope.send = function() {
var job = { job: { klass: 'msg', args: [$scope.msg]}};
$http.post('/contact',job).
success(function(data){
$scope.success = true;
$scope.msg = {};
@hashmal
hashmal / gist:874792
Created March 17, 2011 17:54
[Lua] Print table contents recursively
-- Print contents of `tbl`, with indentation.
-- `indent` sets the initial level of indentation.
function tprint (tbl, indent)
if not indent then indent = 0 end
for k, v in pairs(tbl) do
formatting = string.rep(" ", indent) .. k .. ": "
if type(v) == "table" then
print(formatting)
tprint(v, indent+1)
else