Skip to content

Instantly share code, notes, and snippets.

View jaklan's full-sized avatar
🐍

Jakub Lański jaklan

🐍
View GitHub Profile
@jaklan
jaklan / wait-for-element.js
Last active December 30, 2022 08:34
[Tampermonkey] waitForElement function
function waitForElement(selector, fallbackSelector) {
"use strict";
return new Promise((resolve, reject) => {
if (document.querySelector(selector)) {
return resolve(document.querySelector(selector));
}
const observer = new MutationObserver((mutations) => {
if (document.querySelector(selector)) {
@jaklan
jaklan / aws-iam-ic.js
Last active March 6, 2025 19:02
[Tampermonkey] Confirm login in AWS IAM Identity Center
// ==UserScript==
// @name AWS IAM Identity Center
// @namespace http://tampermonkey.net/
// @version 1.0
// @author Jakub Lanski
// @description Confirm login in AWS IAM Identity Center.
// @icon https://www.google.com/s2/favicons?sz=64&domain=aws.amazon.com
// @match https://*.awsapps.com/start/*
// @require https://gist.github.com/jaklan/2fb5d31797e0dc320d1450119e14f463/raw
// ==/UserScript==