The popular open-source contract for web professionals by Stuff & Nonsense
- Originally published: 23rd December 2008
- Revised date: March 15th 2016
- Original post
// Center anything horizontally, vertically or both (assuming that the parents position is set to relative) | |
// Codepen Example Usage: https://codepen.io/anon/pen/yPbgYW | |
@mixin center($center: 'all') { | |
position: absolute; | |
@if $center == 'all' { | |
top: 50%; | |
left: 50%; | |
transform: translate(-50%, -50%); |
var delete_action_el = "btn primary-btn delete-action"; | |
var delete_button_el = "js-actionDelete"; | |
// Scroll | |
setInterval(function () { | |
window.scrollTo(0, document.body.scrollHeight); | |
}, 1000); | |
var _tweets = document.getElementsByClassName(delete_button_el); |
from selenium import webdriver | |
from selenium.webdriver.common.keys import Keys | |
import time | |
import random | |
import sys | |
def print_same_line(text): | |
sys.stdout.write('\r') | |
sys.stdout.flush() |
// 1. go to your twitter feed with tweets and replies | |
// for example, mine was twitter.com/6a68/with_replies | |
// 2. scroll all the way down to the bottom of the page. | |
// I suppose you could automate this with JS, but I didn't. | |
// this function will delete tweets you can delete, i.e. not retweets: | |
function deleteTweets() { | |
// find the next delete button in the DOM (next deletable tweet) | |
// and click the delete button. I wanted to keep the first tweet, | |
// which is why the index here is 1. | |
if (!$('.js-actionDelete').length) { |
<?php | |
/** | |
* Adds Schema pieces to our output. | |
* | |
* @param array $pieces Graph pieces to output. | |
* @param \WPSEO_Schema_Context $context Object with context variables. | |
* | |
* @return array $pieces Graph pieces to output. | |
*/ |
import Router from 'next/router' | |
import React from 'react' | |
const DONE_DURATION = 250 | |
export const RouteIndicator = () => { | |
const [loading, setLoading] = React.useState(null) | |
const [timeoutId, setTimeoutId] = React.useState(null) | |
const onLoad = () => setLoading(true) |
// Gist by acesmndr@gmail.com Rev 2.1.2 May 15, 2019 | |
// go to your insta profile page (not the home page). It looks something like this: https://instagram.com/YOUR_PROFILE | |
// Open javascript console "Ctrl + Shift + i" in Windows/Linux and "Cmd + option + i" in Mac. | |
// Paste the entire code below to the console and hit enter | |
// You will get the list of people whom you follow but who don't follow you back and viceversa as well as the entire list of followers and following | |
var following = [], | |
followers = [], | |
followersCount = 0, | |
followingCount = 0, |