Skip to content

Instantly share code, notes, and snippets.

View arashmilani's full-sized avatar

Arash Milani arashmilani

View GitHub Profile
@arashmilani
arashmilani / twitter-activity-tweets-remover.js
Last active May 26, 2019 11:06
Twitter "activity tweets" remover
// ==UserScript==
// @name twitter-activity-tweets-remover
// @namespace http://arashmilani.com/
// @version 0.1
// @description Twitter "activity tweets" remover
// @author Arash Milani
// @match https://*twitter.com/*
// @grant none
// ==/UserScript==

Keybase proof

I hereby claim:

  • I am arashmilani on github.
  • I am arashmilani (https://keybase.io/arashmilani) on keybase.
  • I have a public key ASBAHKbqmQ3luqdiylYs0-VSq8T1dMERacsT3p3q-OHUaAo

To claim this, I am signing this object:

@arashmilani
arashmilani / wp-google-map-shortcode.php
Last active June 8, 2016 09:09
A simple WordPress shortcode for Google Maps
<?php
/*
Usage example:
[googlemap height='300' lat='38.0658495' lng='46.3238727'
zoom='17' title='A wonderfull place', icon='../wp-content/themes/my-theme/images/pin.png' disableDefaultUI='true']
*/
function google_map ($atts) {
$height = isset($atts['height']) ? $atts['height'] : 300;
@arashmilani
arashmilani / gist:4732488
Created February 7, 2013 17:13
Trying to find much better way to assert Types in javascript rather than comparing types in string using typeof
function assertType(obj, type) {
return obj.constructor.name === type.name
}
console.info(assertType("test", String)); //true
console.info(assertType(1, String)); //false
console.info(assertType(1, Number)); //true
function Book(){};
function Desk(){};