TIL: How to get a specific number of lines above and below a matched term with grep Back Story I was trying to search through git logs to get a specific change that happened sometime in February to a specific file. I don't remember how to format git logs off
TIL: Sending cookies with the fetch API Today I was trying desperately to create a login form for a side project I'm working on and I could not get the session to persist from page load to page load in
TIL: Destructuring function arguments in JavaScript So check this out! If you have a function that accepts an object as an argument and you don't want pull each of the properties of that argument out one by one, what
npm TIL: Run scripts after npm install with postinstall The other day when I was upgrading React Native I ran into this issue here. Basically, there was a naming collision between files in the fbjs dependency which was scattered throughout a few
TIL: Edit font metadata with TTX Today I needed to change the Full Name propery of a .ttf font file I was working with. After some searching around the interwebs I found TTX, a script written in Python which
TIL: Object Spread Operator The JavaScript spread operator is awesome! Previously when I wanted to merge two objects I would have to pull in underscore or lodash and do something like this. var obj = _.extend(objectOne, objectTwo,
React Native Simple Store I just recently started working with React Native and right away I had a use for the AsyncStorage utility. The folks at Facebook suggest that you wrap AsyncStorage if you are going to
Conform Backbone model data to schema before calling set When doing basic CRUD on Backbone models there can be instances when it is helpful to have a defined schema for model properties. Since properly typing data is not something that JavaScript is
Use invoke to change properties on each model in Backbone collection Here's a quick tip. If you need to set the same property on each model in a Backbone collection check out the following snippet.this.collectionName.invoke('set', { isSet: true }); Invoke can be
git Create a branch from existing branch in git TL;DR; The command you need is git checkout -b new-branch existing-branchDo you ever find yourself working on a new feature for program you're writing and making lots of good progress when a