Skip to content

Instantly share code, notes, and snippets.

View 0xflotus's full-sized avatar
👨‍💻
coding

0xflotus

👨‍💻
coding
View GitHub Profile

Cheat sheet: Arrays

JavaScript Arrays are a very flexible data structure and used as lists, stacks, queues, tuples (e.g. pairs), etc. Some

Using Arrays

Creating Arrays, reading and writing elements:

@JamieMason
JamieMason / es6-compose.md
Last active May 17, 2022 17:38
ES6 JavaScript compose function

ES6 JavaScript Compose Function

Definition

const compose = (...fns) =>
  fns.reduceRight((prevFn, nextFn) =>
    (...args) => nextFn(prevFn(...args)),
    value => value
 );