Skip to content

Instantly share code, notes, and snippets.

View tratnayake's full-sized avatar

Thilina Ratnayake tratnayake

View GitHub Profile
var globalVar = "This is just here to show you that you don't need to wrap an async function and pass vars from the top";
function asyncwfExplained(startArg1){
async.waterfall([
//The first function always starts with a callback object
function(callback){
someAsyncFunction(startArg1,function(err,data){
var f1result = data;
//the first param is null (because we're saying that no errors were produced)
//the second param is whatever data you want to pass forward (e.g so if you want)
#main area
printSomething("Test")
#define functions
def printSomething(printValue)
puts printValue
end
<!doctype html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title></title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="apple-touch-icon" href="apple-touch-icon.png">
<link rel="stylesheet" href="css/bootstrap.min.css">
<div class="container-fluid">
<!-- Your fluid content goes here :) -->
</div>
<div class="container>
<!-- Your padded content goes here! -->
</div>
<div class="container-fluid> <!-- The outside/background container -->
<!-- This content will take the full width of the page -->
<div class="container>
<!-- This content will be padded to the center -->
</div>
</div> <!-- End of outside/background container>
<div class="col-sm-4"
<!-- Content goes in here! -->
</div>
<div class="col-sm-4"><h1>I'm a col</h1></div>
<div class="col-sm-4"><h1>I'm a col</h1></div>
<div class="col-sm-4"><h1>I'm a col</h1></div>
<div class="col-sm-4"><h1>I'm a col</h1></div>
<div class = "col-sm-4">Column!</div>
<div class = "col-sm-4">Column!</div>
<div class = "col-sm-4">Column!</div>
<!-- New row gets created from here -->
<div class = "col-sm-4">Column!</div>
<!-- Notice the size of the next columns
<div class = "col-sm-8">I'm twice as big!!</div>
<div class="colcard col-sm-6 col-md-3">
<!-- Phones -->
</div>
<div class="colcard col-sm-6 col-md-3">
<!-- Tablets -->
</div>
<div class="colcard col-sm-6 col-md-3">
<!-- Laptops -->
</div>
<div class="colcard col-sm-6 col-md-3">