notes from http://flexbox.io. source code available at https://github.com/wesbos/What-The-Flexbox. nice covers from http://coverr.co/
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
| function Calculator(inputString){ | |
| this.tokenStream = this.lexer(inputString); | |
| console.log(this.tokenStream); | |
| } | |
| Calculator.prototype.peek = function () { | |
| return this.tokenStream[0] || null; | |
| }; |
In many card games, there are certain cards or combinations of cards that "beat" or "trump" others. For example, in poker, a straight beats a three of a kind, and a three of a kind beats a two of a kind. Likewise, in the case of ties between two similar hands, an Ace will beat a King, and so on and so forth.
Precedence in programming languages is just like this. In regards to this context, we know quite a couple different ways that this context can be set - first there's the normal way (set dynamically as method on an object), then there's the new keyword, then also call, apply and bind, and now arrow functions. But what happens if these different methods collide? For example:
const Dog = (name, breed) => {
my notes ripped shamelessly from https://webpack.academy
- add webpack
yarn add webpack --dev. this adds to devDependencies - add
{"build": "webpack"}underscriptstopackage.json. optionally:
"watch": "webpack --watch","start:dev": "webpack -w & nodemon server/app.js","build-watch": "npm run build -- -w","start-watch": "nodemon server/start.js --watch server --watch db --watch index.js --watch package.json","start-dev": "cross-env NODE_ENV=development npm run start-watch",
| function timeDifference(current, previous) { | |
| const milliSecondsPerMinute = 60 * 1000 | |
| const milliSecondsPerHour = milliSecondsPerMinute * 60 | |
| const milliSecondsPerDay = milliSecondsPerHour * 24 | |
| const milliSecondsPerMonth = milliSecondsPerDay * 30 | |
| const milliSecondsPerYear = milliSecondsPerDay * 365 | |
| const elapsed = current - previous |
| license: gpl-3.0 |
| license: gpl-3.0 |
| license: gpl-3.0 |
format/rules: http://speak.reactrally.com/events/react-rally-2018
React Mind, Beginner's Mind
What is your talk about?