Skip to content

Instantly share code, notes, and snippets.

@impactmass
impactmass / cvson.json
Last active August 29, 2015 14:25 — forked from mcrider/cvson.json
{
"firstName": "Reginald",
"lastName": "Fake",
"gender": "Male",
"dob":"1983-01-01",
"email":"[email protected]",
"address": {
"streetAddress": "21 Fake Street",
"city": "New York City",
"state": "NY",
@impactmass
impactmass / iOS Scroll Issue.markdown
Created September 11, 2015 14:58
iOS Scroll Issue
@impactmass
impactmass / .zshrc
Created October 24, 2015 14:37
zshrc
# include z
. /usr/local/Cellar/z/1.8/etc/profile.d/z.sh
plugins=(git extract node npm bower brew cloudapp)
source $ZSH/oh-my-zsh.sh
HISTSIZE=SAVEHIST=100000
setopt sharehistory
@impactmass
impactmass / Magazine Layout Attempt #2.markdown
Created February 13, 2016 18:30
Magazine Layout Attempt #2
@impactmass
impactmass / read-more-liquid-post.html
Created February 25, 2016 07:05
read more link in jekyll blog using liquid
{% capture content_words %}
{{ post.content | number_of_words }}
{% endcapture %}
{% capture excerpt_words %}
{{ post.content | truncatewords: 250 | number_of_words }}
{% endcapture %}
{% if content_words != excerpt_words %}
<p class="right"><a href="{{site.baseurl}}{{ post.url }}">Read more</a></p>
@impactmass
impactmass / loader-dir.js
Created April 13, 2016 11:09
Add three-dot style loader to specific elements that hold API loaded content
angular.module('app', [])
.directive('loader', function() {
return {
restrict: 'A',
link: function link(scope, element, attrs) {
var loaderHTML = angular.element('<div class="loading-spinner-context"><div class="loading-spinner-wrapper"' + 'id="app-loader"><span class="loading-spinner white"><i class="one"></i><i class="two"></i><i class="three"></i></span></div></div>');
scope.$watch(attrs.loader, function(newVal) {
if (!newVal) {
if ($(element).children('.loading-spinner-context').length) {
$('.loading-spinner-context').css('display', 'block');
@impactmass
impactmass / use_of_func.js
Last active May 29, 2017 09:51
Beginner: Use of descriptive functions + promise chain
const UserController = {
create(req, res) {
const userData = req.body;
const query = {
where: { email: userData.email }
};
const defaultRole = {
where: { title: 'Writer' }
};
@impactmass
impactmass / .eslintrc
Created May 30, 2017 09:39
sample_eslintrc_mostly_reasonable_rules
{
"env": {
"browser": true,
"es6": true,
"node": true,
"mocha": true
},
"extends": "airbnb",
"rules": {
"comma-dangle" : [2, "never"],
@impactmass
impactmass / docker_load__input.md
Last active June 23, 2018 19:54
Accept input from a file

I've always used this to load an image from a tar

docker load < image.tar

is same as:

docker load --input image.tar

Useful when I had to run something like:

Keybase proof

I hereby claim:

  • I am impactmass on github.
  • I am impactmass (https://keybase.io/impactmass) on keybase.
  • I have a public key ASBqgz36Iy3-ppxP0aPRQJbtEk0fpRlGkOpYtDXDHYq20Ao

To claim this, I am signing this object: