// no closure
for (var i=1; i<=5; i++) {
setTimeout(() => {
console.log(i); // 6, 6, 6, 6, 6
}, i*1000);
}
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
// basics | |
type TSimpleType = { | |
// prefer to name flow types with 'T*' syntax | |
stringProp: string, | |
nullableStringProp: ?string, | |
optionalStringProp?: string, | |
optionalAndNullableStringProp?: ?string, | |
type: 'a' | 'b' | 'c', | |
}; |
- Only style what you need. Create classes or IDs to allow targeting of specific elements.
- Use
container
to create padding and margins that center based on screen width. - Use
container-fluid
to allow for expansion to the whole screen width while keeping a natural padding.
- 10 Years of Git:
![image-inflation][]
Explores inflation by visualizing relative prices in two different years.
Mouseover to view details on relative CPI and prices. Click on a tile to freeze details. 2015 years are highlighted in gold.
The project is created using D3.js.
Dances with Factors visualizes prime factorization of integers.
The fundamental theorem of arithmetic states that every integer greater than 1 is either prime itself or a product of prime numbers.
The project is created using D3.js.