- Undefined => undefined
- Null => null
- Boolean => true
- String => "hello"
- Number => 2
- Object (Object can be refered as Hash as key value pairs.)
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="http://code.jquery.com/jquery-2.1.0.min.js"></script> | |
<meta charset="utf-8"> | |
<title>JS Bin</title> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/ramda/0.8.0/ramda.min.js"></script> | |
<script src="http://looprecur.com/hostedjs/pointfree.browser.js"></script> | |
<script src="http://looprecur.com/hostedjs/monoids.js"></script> | |
<script src="http://looprecur.com/hostedjs/maybe.js"></script> |
var propMap = { | |
val: "value", | |
html: "innerHTML" | |
}; | |
for(var fnName in propMap){ | |
$.prototype[fnName] = function(prop){ | |
return function(){ | |
return this[prop]; | |
} |
/** | |
* Why we call javascript as a first class functions | |
*/ | |
// Create a function | |
var square = function(x){ | |
return x*x; | |
}; | |
// Return a function |
Sometimes you want to have a subdirectory on the master
branch be the root directory of a repository’s gh-pages
branch. This is useful for things like sites developed with Yeoman, or if you have a Jekyll site contained in the master
branch alongside the rest of your code.
For the sake of this example, let’s pretend the subfolder containing your site is named dist
.
Remove the dist
directory from the project’s .gitignore
file (it’s ignored by default by Yeoman).
/** | |
* To Array | |
*/ | |
function toArray(args) { | |
return [].slice.call(args); | |
} | |
/** | |
* Curry function | |
*/ |
description "app/http_server.js" | |
author "Samar - http://samarpanda.com" | |
# used to be: start on startup | |
# until we found some mounts weren't ready yet while booting: | |
start on started mountall | |
stop on shutdown | |
# Automatically Respawn: | |
respawn |
To explain this architecture i have considered nginx as the webserver. For this version we haven't used S3. We might implement that in future as per the usage.
systemd
to create the service.