Skip to content

Instantly share code, notes, and snippets.

View elzii's full-sized avatar

Alexander Zizzo elzii

View GitHub Profile
@elzii
elzii / simulate_mouse_action.js
Created April 21, 2023 17:53 — forked from huozhi/simulate_mouse_action.js
simulate click and hover mouse action on web with js
const mouseEventOf = (eventType) => (element, x, y) => {
const rect = element.getBoundingClientRect()
const event = new MouseEvent(eventType, {
view: window,
bubbles: true,
cancelable: true,
clientX: rect.left + x,
clientY: rect.top + y,
})

Disable Device Enrollment Program (DEP) notification on macOS Monterey.md

NB! command-R is replaced with holding the power button on M1 macs.

With full reinstall (recommended)

   a. Boot into recovery using command-R during reboot, wipe the harddrive using Disk Utility, and select reinstall macOS

   b. Initial installation will run for approximately 1 hour, and reboot once

lat lng pop
15.3547 44.2066 2008000
15.421 45.334 16794
15.6917 43.6021 208287
13.9759 44.1709 234837
14.7979 42.953 780000
13.0582 44.8838 66288
13.6045 44.0394 751000
16.9398 43.8498 105542
14.5575 44.3875 191259
2975c.v.fwmrm.net
2mdn.net
ad-g.doubleclick.net
ad.doubleclick.net
ad.mo.doubleclick.net
ad.youtube.com
ads.doubleclick.net
ads.youtube.com
adservice.google.com
analytic-google.com
2975c.v.fwmrm.net
2mdn.net
ad-g.doubleclick.net
ad.doubleclick.net
ad.mo.doubleclick.net
ad.youtube.com
ads.doubleclick.net
ads.youtube.com
adservice.google.com
analytic-google.com
@elzii
elzii / data
Last active July 7, 2020 21:43
Example file to test getting data from API
{
"items": [
1,
2,
3,
4,
5
]
}
@elzii
elzii / script.js
Last active July 7, 2017 00:18
Console script to convert SitePoint table of mimetypes to JSON string - https://www.sitepoint.com/mime-types-complete-list
var data = []
document.querySelectorAll('tbody tr').forEach(el => {
var td = el.querySelectorAll('td')
data.push({
'suffix': td[0].innerHTML.replace(/\./, ''),
'contentType': td[1].innerHTML
})
})
@elzii
elzii / .tmux.conf
Created July 6, 2017 01:33
Sloppy tmux config
# ███ ▄▄▄▄███▄▄▄▄ ███ █▄ ▀████ ▐████▀
# ▀█████████▄ ▄██▀▀▀███▀▀▀██▄ ███ ███ ███▌ ████▀
# ▀███▀▀██ ███ ███ ███ ███ ███ ███ ▐███
# ███ ▀ ███ ███ ███ ███ ███ ▀███▄███▀
# ███ ███ ███ ███ ███ ███ ████▀██▄
# ███ ███ ███ ███ ███ ███ ▐███ ▀███
# ███ ███ ███ ███ ███ ███ ▄███ ███▄
# ▄████▀ ▀█ ███ █▀ ████████▀ ████ ███▄
# ============================================================================
if empty(glob('~/.nvim/autoload/plug.vim'))
silent !curl -fLo ~/.nvim/autoload/plug.vim --create-dirs
\ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
autocmd VimEnter * PlugInstall
endif
call plug#begin('~/.config/nvim/plugged')
Plug 'chriskempson/vim-tomorrow-theme'
@elzii
elzii / .vimrc
Created November 28, 2016 03:53
VIM setup Nov 2016
set nocompatible "We want the latest Vim settings/options.
so ~/.vim/plugins.vim
" ---------------------- Basic Settings -----------------------
syntax enable
set backspace=indent,eol,start "Make backspace behave like every other editor.
let mapleader = ',' "The default is \, but a comma is much better.
set number "Let's activate line numbers.