Skip to content

Instantly share code, notes, and snippets.

View kelsS's full-sized avatar
🍵

Kelsey S. kelsS

🍵
View GitHub Profile
@kelsS
kelsS / Remove videos from Youtube Watch Later playlist.md
Created January 30, 2023 16:28 — forked from astamicu/Remove videos from Youtube Watch Later playlist.md
Script to remove all videos from Youtube Watch Later playlist

UPDATED 22.11.2022

It's been two years since the last update, so here's the updated working script as per the comments below.

Thanks to BryanHaley for this.

setInterval(function () {
    video = document.getElementsByTagName('ytd-playlist-video-renderer')[0];

 video.querySelector('#primary button[aria-label="Action menu"]').click();
@kelsS
kelsS / vanilla-js-cheatsheet.md
Created October 27, 2022 16:11 — forked from thegitfather/vanilla-js-cheatsheet.md
Vanilla JavaScript Quick Reference / Cheatsheet
@kelsS
kelsS / .eslintrc.js
Created September 13, 2022 00:13 — forked from adrianhall/.eslintrc.js
A sample .eslintrc file
var OFF = 0, WARN = 1, ERROR = 2;
module.exports = exports = {
"env": {
"es6": true
},
"ecmaFeatures": {
// env=es6 doesn't include modules, which we are using
"modules": true
@kelsS
kelsS / starter-js-project-files.md
Last active September 13, 2022 02:22
Example starter files for vanilla JS projects.

.nvmrc

16

.gitignore

# Logs
logs
*.log
@kelsS
kelsS / visually-hidden-clip-method.md
Created July 26, 2022 16:09
visually-hidden class using the clip method in CSS. This allows you to place screen reader only text in the DOM. Resource: https://www.a11yproject.com/posts/how-to-hide-content/
.visually-hidden {
    border: 0;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
 width: 1px;
@kelsS
kelsS / visually-hidden-clip-method.md
Created July 26, 2022 16:07
Deque's visually-hidden class using the clip method in CSS. This allows you to place screen reader only text in the DOM.
.visually-hidden {
    border: 0;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
 width: 1px;

Keybase proof

I hereby claim:

  • I am kelss on github.
  • I am kelss (https://keybase.io/kelss) on keybase.
  • I have a public key ASCpkaHqf5QnVkAJhntI9JKYrYbUVbKWkh-RC_VGGo9xkgo

To claim this, I am signing this object:

BEM Cheatsheet

BLOCK

Block encapsulates a standalone entity that is meaningful on its own.

While blocks can be nested and interact with each other, semantically they remain equal; there is no precedence or hierarchy.

Holistic entities without DOM representation (such as controllers or models) can be blocks as well.

@kelsS
kelsS / monad-stream-example.js
Created February 13, 2019 18:06 — forked from mpj/monad-stream-example.js
This is the code from Monads - episode #21 of FunFunFunction (https://www.youtube.com/playlist?list=PL0zVEGEvSaeFSwPn06GKArptSxiP1Gff8)
const fetch = require('node-fetch')
const Bacon = require('baconjs')
function getInPortuguese(word) {
// Google Translate API is a paid (but dirt cheap) service. This is my key
// and will be disabled by the time the video is out. To generate your own,
// go here: https://cloud.google.com/translate/v2/getting_started
const apiKey =
'AIzaSyB4DyRHIsNhogQXmH16YKbZfR-lTXrQpq0'
const url =
@kelsS
kelsS / gist:4aaab6cace9bfa050a22cf2d65ce263a
Last active January 29, 2019 15:36 — forked from skull-squadron/gist:952660
Restart ssh-agent
killall ssh-agent; eval $(ssh-agent)