Skip to content

Instantly share code, notes, and snippets.

@kslstn
kslstn / getBookmarksFromRaindrop.ts
Last active August 10, 2026 20:13
Get favorite bookmarks from Raindrop
import { default as EleventyFetch } from "@11ty/eleventy-fetch";
interface Bookmark {
id: string;
link: string;
domain: string;
title: string;
excerpt: string;
note: string;
tags: string[];
@kslstn
kslstn / themes.js
Last active July 2, 2023 17:04
My script to add theming support and switch between light mode and dark mode
// Find if user has set a preference and react to changes
(function initializeTheme(){
syncBetweenTabs()
listenToOSChanges()
enableTheme(
returnThemeBasedOnLocalStorage() ||
returnThemeBasedOnOS() ||
returnThemeBasedOnTime(),
false)
}())