A ZSH theme optimized for people who use:
- Solarized
- Git
- Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)
For Mac users, I highly recommend iTerm 2 + Solarized Dark
| // A common redux pattern when dealing with async functions is to use thunk. | |
| // This usually means your action returns a new function instead of an action object, | |
| // and the thunk middleware will make it all work. Example: | |
| const asyncAction = () => dispatch => setTimeout(() => dispatch(someOtherAction()), 10000); | |
| // Now: maybe that async stuff going on is calling some API which you don't want to overload | |
| // with request, and that's what debounce is for. | |
| // This is an example of a debounced function which will only be calleable once every second. | |
| import { debounce } from 'lodash'; | |
| const debouncedFn = debounce(() => callApi(), 1000, { leading: true, trailing: false }); |
Awesome PHP has been relocated permanently to its own Github repository. No further updates will made to this gist.
Please open an issue for any new suggestions.