Skip to content

Instantly share code, notes, and snippets.

View constantins2001's full-sized avatar
🏠
Working from home

Constantin Schreiber constantins2001

🏠
Working from home
View GitHub Profile
@constantins2001
constantins2001 / status_setter.js
Last active January 27, 2023 12:26
Script to properly update Teams status using IdleDetector API
// Leaving Teams open in a separate tab causes "away" status and stops updating messages after a while.
// This script uses Chrome's IdleDetector API to properly set the status and keep Teams active.
function waitForElm(selector) {
return new Promise(resolve => {
if (document.querySelector(selector)) {
return resolve(document.querySelector(selector));
}
const observer = new MutationObserver(mutations => {

Keybase proof

I hereby claim:

  • I am sauberesache on github.
  • I am sauberesache (https://keybase.io/sauberesache) on keybase.
  • I have a public key ASAN5NBtZW3xey2QKDaodUUl7bBPy8-pKW7az4FOQ6J1wgo

To claim this, I am signing this object: