Skip to content

Instantly share code, notes, and snippets.

View clecidor's full-sized avatar
🎯
Focusing

Clay Clecidor clecidor

🎯
Focusing
View GitHub Profile
@clecidor
clecidor / oscillate.js
Last active September 13, 2019 07:32
oscillate.js
function oscillate(intervals, threshhold) {
intervals = intervals || (-1*intervals) || 1;
threshhold = threshhold || (-1*threshhold) || 1;
const distance = threshhold * 2;
const minute = 60;
const rateOfChange = (distance / minute);
console.log({ intervals, threshhold, distance, rateOfChange });
@denisemenov
denisemenov / instagram-feed.js
Created October 28, 2017 17:23
Instagram Auto Like
function timeOut(min, max) {
return Math.random() * (max - min + 1000) + min;
}
function getHeartElement() {
var knownHeartElementNames = ["coreSpriteHeartOpen", "coreSpriteLikeHeartOpen"];
var i = 0;
for (i = 0; i < knownHeartElementNames.length; i++) {
var heartElement = document.querySelector('.' + knownHeartElementNames[i]);
if (heartElement != undefined) {
@sbolel
sbolel / insta-like-feed.js
Created June 17, 2017 02:13
Instagram auto-liker in the browser using Chrome Dev Tools
/**
* @desc Injects jQuery into Instagram feed page and likes X posts at a time
*
* Usage: Open https://www.instagram.com/ in Chrome and login to view your feed;
* run this script in the JS console to like posts in your feed in batches.
*
* @param {number} start - starting post index (should be 0 unless manually continuing a prev. exec.)
* @param {number} count - number of posts to like per batch (like X posts, wait a little, repeat)
* @param {number} interval - number of milliseconds to wait between batches, +/- some randomness
*/
@lfreneda
lfreneda / instagram auto follow
Last active June 6, 2021 04:13
instagram auto follow
var index = 0;
var buttons = null;
var scrollCount = 0;
var followedCount = 0;
function clickAndWait() {
if (buttons === null) {
buttons = document.querySelectorAll('li button');
}

2015-01-29 Unofficial Relay FAQ

Compilation of questions and answers about Relay from React.js Conf.

Disclaimer: I work on Relay at Facebook. Relay is a complex system on which we're iterating aggressively. I'll do my best here to provide accurate, useful answers, but the details are subject to change. I may also be wrong. Feedback and additional questions are welcome.

What is Relay?

Relay is a new framework from Facebook that provides data-fetching functionality for React applications. It was announced at React.js Conf (January 2015).

@anthonysterling
anthonysterling / Vagrantfile
Last active April 29, 2020 15:28
Handy Vagrantfile for IE testing with Vagrant.
# Usage: IE={box} vagrant up
#
# Eg. IE=XPIE6 vagrant up
boxes = {
"XPIE6" => "http://aka.ms/vagrant-xp-ie6",
"XPIE8" => "http://aka.ms/vagrant-xp-ie8",
"VistaIE7" => "http://aka.ms/vagrant-vista-ie7",
"Win7IE8" => "http://aka.ms/vagrant-win7-ie8",
"Win7IE9" => "http://aka.ms/vagrant-win7-ie9",
@elidickinson
elidickinson / html_email_buttons_1.html
Last active May 29, 2024 02:15
HTML email buttons that work
<div>
<!--[if mso]>
<v:roundrect xmlns:v="urn:schemas-microsoft-com:vml" xmlns:w="urn:schemas-microsoft-com:office:word" href="http://www.EXAMPLE.com/" style="height:40px;v-text-anchor:middle;width:300px;" arcsize="10%" stroke="f" fillcolor="#d62828">
<w:anchorlock/>
<center style="color:#ffffff;font-family:sans-serif;font-size:16px;font-weight:bold;">
Button Text Here!
</center>
</v:roundrect>
<![endif]-->
<![if !mso]>
@jbenet
jbenet / simple-git-branching-model.md
Last active June 17, 2024 14:53
a simple git branching model

a simple git branching model (written in 2013)

This is a very simple git workflow. It (and variants) is in use by many people. I settled on it after using it very effectively at Athena. GitHub does something similar; Zach Holman mentioned it in this talk.

Update: Woah, thanks for all the attention. Didn't expect this simple rant to get popular.

@ck-on
ck-on / ocp.php
Last active May 18, 2024 22:35
OCP - Opcache Control Panel (aka Zend Optimizer+ Control Panel for PHP)#ocp #php #opcache #opcode #cache #zend #optimizerplus #optimizer+
<?php
/*
OCP - Opcache Control Panel (aka Zend Optimizer+ Control Panel for PHP)
Author: _ck_ (with contributions by GK, stasilok)
Version: 0.1.7
Free for any kind of use or modification, I am not responsible for anything, please share your improvements
* revision history
0.1.7 2015-09-01 regex fix for PHP7 phpinfo
0.1.6 2013-04-12 moved meta to footer so graphs can be higher and reduce clutter
@justfalter
justfalter / how_to_install_qcachegrind_on_osx.txt
Created June 16, 2011 16:04
How to install qcachegrind (kcachegrind) on OSX Snow Leopard
SUMMARY
I like to use kcachegrind for doing profiling on my ruby code. Most of my development
is done on OSX, and while you can install kcachegrind via macports, it takes forever
because it has to build KDE, as well. Much to my surprise, the fine folks who
wrote kcachegrind also made a QT version, qcachegrind. I was able to build this on
OSX without too much effort, only having to install QT and GraphViz. Yippie!
I'm running OSX 10.6.7, with Xcode 4. My default gcc/g++ version is 4.2. I'm sure
it will build just fine on earlier versions of Xcode, but I haven't tested it.