Skip to content

Instantly share code, notes, and snippets.

View nickytonline's full-sized avatar
:octocat:

Nick Taylor nickytonline

:octocat:
View GitHub Profile
@nickytonline
nickytonline / local-npm-task.xml
Last active January 27, 2016 20:31
A Task for Windows Task Scheduler to run local-npm
<?xml version="1.0" encoding="UTF-16"?>
<Task version="1.2" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task">
<RegistrationInfo>
<Date>2016-01-21T08:54:47.1813619</Date>
<Author>YOUR_DOMAIN\YOUR_USER</Author>
<Description>Runs local-npm a local version of npm that grabs packages from it's server if not already fetched. This essentially allows you to run npm offline, assuming you've installed the packages you need at least once.</Description>
</RegistrationInfo>
<Triggers>
<LogonTrigger>
<Enabled>true</Enabled>
@nickytonline
nickytonline / repls.md
Created December 10, 2015 04:47
A list of useful REPLs
@nickytonline
nickytonline / compose.ts
Last active December 8, 2015 02:11
Messing around with functional progamming in TypeScript
export default function compose<T>(...functions: { (x: T): T }[]) {
return x => functions.reduce((previous, current) => x => current(previous(x)))(x);
}
/* usage:
const composed = compose<number>(x => x * 2,x => x * 3, x => x * 4);
console.log(composed(4)) //96
or
@nickytonline
nickytonline / domBubbling.html
Last active August 29, 2015 14:15
Event management in the DOM via bubbling for Handlebars templating POC
<html>
<head>
<title>Client-Side Event Binding with HandleBards POC</title>
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css" />
<!--[if IE]>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<![endif]-->
<style type="text/css">
#logger {
height: 250px;