This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // The businesspeople among you will know that it's often not easy to find an | |
| // appointment. In this kata we want to find such an appointment automatically. | |
| // You will be given the calendars of our businessperson and a duration for the | |
| // meeting. Your task is to find the earliest time, when every businessperson is | |
| // free for at least that duration. | |
| // | |
| // Example Schedule: | |
| // | |
| // Person | Meetings | |
| // -------+----------------------------------------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Description: | |
| // | |
| // One of the services provided by an operating system is memory management. | |
| // The OS typically provides an API for allocating and releasing memory in a | |
| // process's address space. A process should only read and write memory at | |
| // addresses which have been allocated by the operating system. In this kata you | |
| // will implement a simulation of a simple memory manager. | |
| // | |
| // JavaScript has no low level memory API, so for our simulation we will simply | |
| // use an array as the process address space. The memory manager constructor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // | |
| // * Given some data that looks like this: | |
| // | |
| // let data = [ | |
| // { | |
| // key: 'a', | |
| // value: 'a1', | |
| // children: [ | |
| // { | |
| // key: 'b', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const arr = [1,2,3]; | |
| const otherArr = [3,4,5]; | |
| arr.some(a => otherArr.some(b => a === b)); // => true | |
| // using a collection and comparing with keys | |
| const collection = [{a: 1}, {a: 2}, {a: 3}]; | |
| const collection2 = [{a: 3}, {a: 4}, {a: 5}]; | |
| collection.some(a => collection2.some(b => a.a === b.a)); // => true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # manually specify syntax | |
| :set syntax=js | |
| // view 'recent' files | |
| :buffers // open a 'recent' file | |
| :buffer nameFromList | |
| // diff file against any arbitrary text in v-split |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "root": true, | |
| "env": { | |
| "es6": true, | |
| "browser": true | |
| }, | |
| "rules": { | |
| "indent": [2, "tab"], | |
| "strict": [2, "global"], | |
| "no-use-before-define": 0, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*============================================================================= | |
| = Scales | |
| =============================================================================*/ | |
| // | |
| // Text | |
| // | |
| $textSizes: ( | |
| (xxs, .8rem), | |
| (xs, 1rem), | |
| (sm, 1.2rem), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*============================================================================= | |
| = Scales | |
| =============================================================================*/ | |
| .text-xxs { | |
| font-size: 0.8rem; | |
| } | |
| .text-xs { | |
| font-size: 1rem; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # -------------------------------------------------------------------------------------------------------- | |
| # BASIC ACTIONS | |
| # ------------------------------------------------------------------------------------------------------- | |
| # start up a new machine | |
| docker-machine create --driver virtualbox dev | |
| # list VMs | |
| docker-machine ps |