Claude Code productivity tips
Keyboard shortcuts, fullscreen TUI mode, status bar customization, and IDE integration make Claude Code easier to use and keep prompts, history, and code context visible.
Tracking External API Performance in Rails Logs
Track time, call counts, and token usage for slow external APIs in Rails logs and Server Timing, making LLM regressions and prompt bloat visible without a debugger.
A restrictive (but still practicable) CSP for Rails projects
A strict Content Security Policy for Rails limits scripts to nonce-approved sources while keeping styles, images, forms, and fonts workable.
Sending newsletters via rapidmail with SMTP and one-click unsubscribe
Newsletter delivery via SMTP with rapidmail, plus Gmail-compatible one-click unsubscribe using signed tokens and List-Unsubscribe headers.
Controlling the order of DOM event listeners
DOM event listeners run in registration order, so forcing a handler to fire first or last can require capture, delegation, or a related event.
Working with lists of DOM elements in JavaScript
DOM query results can be live, array-like lists rather than true arrays, and some APIs include text nodes or comments as children.
Git: Finding changes in ALL commits
Git searches are often limited to the current branch, so changes can be missed across other refs, merges, or reflog entries. git log can search broader history with ref and path filters.
Making minimal updates to DOM trees using morphdom / idiomorph
Replacing DOM fragments with innerHTML wipes state such as form values, scroll position, and custom-element data. morphdom and idiomorph preserve existing nodes by applying minimal changes.
GoodJob: Ensure you get notified about background exceptions
ActiveJob and GoodJob can swallow exceptions, causing silent background job failures. Subscribing to job events and on_thread_error restores exception notifications and adds failure context.
Improve accessibility with [aria-required] in SimpleForm
Screen readers can miss required fields when forms rely only on visual asterisks; aria-required adds an accessible required-state announcement without browser validation.
How to auto-resize a textarea (or other inputs) in pure CSS
field-sizing: content lets textareas and other inputs grow to fit their contents, but Firefox and Safari still need a JavaScript fallback.
Adding comments to ambiguous database columns
Ambiguous database columns can need schema comments when meaning depends on history or code. Units, boolean flags, timestamps, and STI-specific fields benefit most.
How to: Self-hosted fonts via NPM packages
Self-hosted webfonts can satisfy GDPR requirements without bundling font files manually. Fontsource NPM packages include weights, glyph sets, and smarter CSS loading.
Better performance insights with gem `rails_performance`
rails_performance adds low-effort performance monitoring for Rails apps, surfacing slow endpoints, request timing, query breakdowns, and custom events with Redis-backed dashboards.
Controlling smooth scrolling in browsers
Browser scrolling can switch between instant and animated movement depending on CSS, JavaScript options, and user settings; behavior and scroll-behavior interact in surprising ways.
Testing Accessibility using Orca
Linux screen reader testing can be noisy and hard to inspect; capturing Orca speech in real time makes spoken output readable during accessibility checks.
Rails: Configuring the default sorting behaviour
Default ordering in ActiveRecord queries falls back to id unless implicit_order_column is set, which can make first and other finder calls return a different record order.
Implementing upload progress and remove button with ActiveStorage DirectUpload
In-place file uploads with ActiveStorage DirectUpload can show progress and support removing a chosen file before form submission.
Implementing authentication and authorization for ActiveStorage blobs/files
Rails ActiveStorage direct uploads are public by default, so unauthenticated users can flood storage and access sensitive blobs without ownership checks.
How to automatically optimize SVG files with esbuild
SVG files often carry metadata and hidden elements that bloat output. svgo can run as an esbuild plugin to optimize them during builds.
Overview of method delegation in Rails
Forwarding methods in Rails reduces deep call chains and boilerplate when exposing data from associated objects or decorators.
Debug your Postgres SQL query plan
Slow SQL queries can hide expensive scans and missed indexes; inspecting the PostgreSQL execution plan helps pinpoint bottlenecks and optimize query performance with explain and pev2.
How to disable telemetry for various open source tools and libraries
Telemetry and analytics in open source CLIs and frameworks often require explicit opt-out settings or environment variables to stop data collection and crash reporting.
How the Date Header Affects Cookie Expiration and Caching
Cookie expiry and HTTP cache lifetimes depend on the Date header when present; missing it can make mocked-time tests and browser caching behave inconsistently.