Skip to content

Instantly share code, notes, and snippets.

View nickx720's full-sized avatar
🦁
Working from home

Nick nickx720

🦁
Working from home
View GitHub Profile
@nickx720
nickx720 / README.md
Created October 21, 2021 16:14
Nylas Secret Santa

Tested on Node v.15.14.0

To run script

node index.js
@nickx720
nickx720 / fantas.js
Created October 28, 2020 16:46
Ord Basis For Coord as per Tom Hardings Fantas Guide
const daggy = require('daggy');
const { merge } = require('ramda');
function fantasyLandDaggy() {
const Coord = daggy.tagged('Coord', ['x', 'y', 'z']);
const Line = daggy.tagged('Coord', ['from', 'to'])
Coord.prototype.equals = function coordEquals(that) {
return this.x == that.x
@nickx720
nickx720 / filterArray.js
Created September 7, 2020 16:16 — forked from jherax/filterArray.js
Filters an array of objects with multiple match-criteria.
/**
* Filters an array of objects using custom predicates.
*
* @param {Array} array: the array to filter
* @param {Object} filters: an object with the filter criteria
* @return {Array}
*/
function filterArray(array, filters) {
const filterKeys = Object.keys(filters);
return array.filter(item => {
@nickx720
nickx720 / ct_notes.txt
Created August 21, 2020 07:20 — forked from buzzdecafe/ct_notes.txt
Category Theory for Programmers: Notes
CATEGORY THEORY FOR PROGRAMMERS
Category Theory 1.1: Motivation and Philosophy
https://www.youtube.com/watch?v=I8LbkfSSR58&index=1&list=PLbgaMIhjbmEnaH_LTkxLI7FMa2HsnawM_
Composability, Abstraction, Reusability
Category Theory is a higher-level language.
Not a practical, executable language.