All Snippets
16 files
css/animations/fade-in.css
Smooth fade-in animation utility classes with directional variants.
css/layouts/holy-grail.css
Classic holy grail layout using CSS Grid — header, footer, main, two sidebars.
css/utilities/reset.css
Modern CSS reset that removes inconsistencies across browsers without over-normalizing.
html/components/blue-header.html
HTML snippet: blue-header.html
html/components/navbar.html
Semantic, accessible navigation bar with mobile hamburger toggle.
html/components/purple-body.html
HTML snippet: purple-body.html
html/components/purple-footer.html
HTML snippet: purple-footer.html
html/layouts/two-column-grid.html
Two-column article layout with sidebar using semantic HTML5 elements.
javascript/async/promise-pool.js
Concurrency-limited promise pool — run N promises at a time from a queue.
javascript/async/retry-fetch.js
Fetch wrapper with automatic retry, exponential backoff, and timeout.
javascript/dom/event-delegation.js
Efficient event delegation pattern to handle dynamic child elements.
typescript/hooks/use-local-storage.ts
React hook for synced localStorage state with SSR safety.
typescript/patterns/observer.ts
Observer / EventEmitter pattern with typed events and automatic cleanup.
typescript/patterns/singleton.ts
Generic Singleton pattern implementation with lazy initialization.
typescript/utils/debounce.ts
Type-safe debounce utility that delays function execution until after a specified wait period.
typescript/utils/deep-merge.ts
Recursive deep merge of two objects with proper TypeScript generics.