I hereby claim:
- I am thelittleblacksmith on github.
- I am eina (https://keybase.io/eina) on keybase.
- I have a public key whose fingerprint is 1296 7512 097A 5B76 61A6 C171 A3F9 34A9 894F FA4B
To claim this, I am signing this object:
<excludefname_rule plat="win" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith=":\Users\" contains_1="\node_modules\" contains_2="*" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
<excludefname_rule plat="win" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith=":\Users\" contains_1="\vendor\" contains_2="*" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
<excludefname_rule plat="win" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith=":\Users\" contains_1="\bower_components\" contains_2="*" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
<excludefname_rule plat="win" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith=":\Users\" contains_1="\AppData\Local\Yarn\" contains_2="*" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
<excludefname_rule plat="win" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith=":\Users\" contains_1="\.svn\" contains_2="*" doesNotContain="*" endsWith="*" hasFileExtension="*" /> |
{ | |
"Print to console": { | |
"prefix": "log", | |
"body": [ | |
"console.log('logging $1', $1);", | |
"$2" | |
], | |
"description": "Log output to console" | |
}, | |
"New Container Component": { |
const Card = (props) => { | |
return ( | |
<div style={{margin: '1em'}}> | |
<img width="75px" src={props.avatar_url} /> | |
<div style={{display: 'inline-block', marginLeft:10}}> | |
<div style={{fontSize: '1.25em', fontWeight: 'bold'}}> | |
{props.name} | |
</div> | |
<div>{props.company}</div> | |
</div> |
class Button extends React.Component { | |
handleClick = () => { | |
this.props.onClickFunction(this.props.incrementValue); | |
}; | |
render (){ | |
return ( | |
<button onClick={this.handleClick}> | |
+{this.props.incrementValue} | |
</button> |
I hereby claim:
To claim this, I am signing this object:
// Bonfire: Caesars Cipher | |
// Author: @thelittleblacksmith | |
// Challenge: http://www.freecodecamp.com/challenges/bonfire-caesars-cipher#?solution=function%20rot13(str)%20%7B%20%2F%2F%20LBH%20QVQ%20VG!%0A%20%20var%20encoded%20%3D%20str.split(%27%27)%3B%20%2F%2Fstr%20-%3E%20array%0A%20%20var%20decoded%20%3D%20%5B%5D%3B%20%2F%2Fcipher%20result%0A%0A%09%2F%2Fiterate%20through%20the%20array%0A%20%20encoded.forEach(function(entry)%20%7B%20%20%09%0A%20%20%20%20%0A%20%20%20%20%2F%2Fchange%20the%20letters%20to%20unicode%0A%20%20%09var%20numbers%20%3D%20entry.charCodeAt(0)%3B%0A%20%20%20%20%0A%20%20%20%20%2F%2Fall%20numbers%20between%2063%20and%2077%20gets%20%2B%2013%0A%20%20%20%20%2F%2Fnumbers%20after%2077%20gets%20-%2013%0A%20%20%20%20%2F%2Fnumbers%20before%2063%20are%20left%20alone%0A%20%20%20%20%2F%2FfromCharCode%20turns%20all%20the%20numbers%20into%20letters%0A%20%20%20%20%2F%2Fthen%20they%27re%20pushed%20into%20the%20decoded%20array%0A%20%20%20%20if(numbers%20%3E%2063%20%26%26%20numbers%20%3C%2078)%7B%0A%20%20%20% |
// Bonfire: Where do I belong | |
// Author: @thelittleblacksmith | |
// Challenge: http://www.freecodecamp.com/challenges/bonfire-where-do-i-belong | |
// Learn to Code at Free Code Camp (www.freecodecamp.com) | |
function where(arr, num) { | |
//push the num in arr | |
arr.push(num); | |
//sort arr -- correctly | |
arr.sort(function(a, b){return a-b;}); |
// Bonfire: Seek and Destroy | |
// Author: @thelittleblacksmith | |
// Challenge: http://www.freecodecamp.com/challenges/bonfire-seek-and-destroy | |
// Learn to Code at Free Code Camp (www.freecodecamp.com) | |
function destroyer(arr) { | |
var args = Array.prototype.slice.call(arguments); | |
args.splice(0,1); //takes out the first argument w/c is the array; arr is now the first array | |
return arr.filter(function(el){ //filtering the first array with the contents of args, arr == el | |
return args.indexOf(el) === -1; |
// Bonfire: Mutations | |
// Author: @thelittleblacksmith (this was a struggle idk why T_T) | |
// Challenge: http://www.freecodecamp.com/challenges/bonfire-mutations?solution=function%20mutation(arr)%20%7B%0A%20%20%20%20var%20test%20%3D%20arr%5B0%5D.toLowerCase().split(%27%27)%3B%0A%20%20%20%20var%20compare%20%3D%20arr%5B1%5D.toLowerCase().split(%27%27)%3B%20%20%20%20%20%20%0A%20%20%20%20for(var%20i%20%3D%200%3B%20i%20%3C%20compare.length%3B%20i%2B%2B)%7B%0A%20%20%20%20%20%20%20%20if(test.indexOf(compare%5Bi%5D)%20%3C%200)%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20return%20false%3B%0A%20%20%20%20%20%20%20%20%7D%20%20%20%20%20%20%20%20%0A%20%20%20%20%7D%20%20%20%20%0A%20%20return%20true%3B%0A%7D%2F%2Fend%20function%0Amutation(%5B%22zyxwvutsrqponmlkjihgfedcba%22%2C%20%22qrstu%22%5D)%3B%0A | |
// Learn to Code at Free Code Camp (www.freecodecamp.com) | |
function mutation(arr) { | |
var test = arr[0].toLowerCase().split(''); | |
var compare = arr[1].toLowerCase().split(''); | |
for(var i = 0; i < compare.length; i++){ | |
// Bonfire: Slasher Flick | |
// Author: @thelittleblacksmith | |
// Challenge: http://www.freecodecamp.com/challenges/bonfire-slasher-flick?solution=function%20slasher(arr%2C%20howMany)%20%7B%0A%20%20return%20arr.slice(howMany)%3B%0A%7D%0A%0Aslasher(%5B1%2C%202%2C%203%5D%2C%202)%3B%0A | |
// Learn to Code at Free Code Camp (www.freecodecamp.com) | |
function slasher(arr, howMany) { | |
return arr.slice(howMany); | |
} | |
slasher([1, 2, 3], 2); |