Skip to content

Instantly share code, notes, and snippets.

@Hugos68
Hugos68 / tailwind-merge-vs-base.md
Last active July 7, 2025 16:15
Comparison of `tailwind-merge` vs `base:` variant

tailwind-merge vs base:

tailwind-merge

What is it?

tailwind-merge is a package that merges a string of tailwind utilities and merges them from left to right in specificity. This means that bg-red-500 bg-blue-500 would produce bg-blue-500. This works effectively when users want to override the classes by providing their own. This does have a runtime cost, which means everytime a user applies a class themselves tailwind-merge will have to figure out wether or not it should be applied based on the already applied classes.

Bundle Size

@Hugos68
Hugos68 / skeleton-v3-guide.md
Last active March 5, 2025 14:59
This is the step by step plan for releasing Skeleton V3

Skeleton V3

This file will go through each step in each piece of software that is part of Skeleton that will need to be changed to have a succesful V3 release. This document is a WIP.

Github

Configure next as the default branch:

/*! tailwindcss v4.0.6 | MIT License | https://tailwindcss.com */@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-serif:ui-serif,Georgia,Cambria,"Times New Roman",Times,serif;--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-red-50:oklch(.971 .013 17.38);--color-red-100:oklch(.936 .032 17.717);--color-red-200:oklch(.885 .062 18.334);--color-red-300:oklch(.808 .114 19.571);--color-red-400:oklch(.704 .191 22.216);--color-red-500:oklch(.637 .237 25.331);--color-red-600:oklch(.577 .245 27.325);--color-red-700:oklch(.505 .213 27.518);--color-red-800:oklch(.444 .177 26.899);--color-red-900:oklch(.396 .141 25.723);--color-red-950:oklch(.258 .092 26.042);--color-orange-50:oklch(.98 .016 73.684);--color-orange-100:oklch(.954 .038 75.164);--color-orange-200:oklch(.901 .076 70.697);--color-orange-300:oklch(.837 .128 66.29);--color-orange-400:oklch(.75 .183
@Hugos68
Hugos68 / output.json
Created November 4, 2024 21:57
Skeleton repo api docs
{
"react": {
"Accordion": [
{
"name": "AccordionContextState",
"properties": [
{
"name": "animDuration",
"type": "number",
"required": true,
{
"unknown": [
{
"componentName": "Accordion",
"interfaces": [
{
"name": "AccordionProps",
"props": [
{
"name": "animDuration",
/**
* https://github.com/CloudCannon/pagefind/blob/production-docs/pagefind_web_js/types/index.d.ts
* Original Author: bglw, CloudCannon
*/
/** Global index options that can be passed to pagefind.options() */
export type PagefindIndexOptions = {
/** Overrides the URL path that Pagefind uses to load its search bundle */
basePath?: string;
/** Appends the given baseURL to all search results. May be a path, or a full domain */
@Hugos68
Hugos68 / App.svelte
Last active May 21, 2024 17:39
`<dialog>` close on click outside Svelte action
<script lang="ts">
const click_outside = (node: HTMLDialogElement) => {
const onclick = (event: MouseEvent) => {
if (event.target === null || !(event.target instanceof Element)) {
return;
}
if (event.target.tagName !== 'DIALOG') {
//This prevents issues with forms
return;
}