Last week a colleague asked me: “Why doesn’t 0.1 + 0.2 equal 0.3?” I smiled, thinking it was just that classic floating-point issue. But when I…
Posts for: #Javascript
Security Pitfalls in Password Generators: From Math.random to crypto.getRandomValues
I was building a password generator tool recently and discovered that many online implementations have serious security flaws. What seems like a si…
JavaScript Number Base Converter: From parseInt to Bitwise Operations
Published: April 29, 2026, 11:00
Building a Mermaid Diagram Editor: From DSL Text to SVG Rendering
I was writing documentation the other day and needed a flowchart. Opened draw.io, dragged some shapes around, felt tedious. Then I remembered Merma…
Building a Line Sorter: From localeCompare to Fisher-Yates Shuffle
Sorting, reversing, or shuffling text lines seems trivial—until you dig into the details. Let’s explore the algorithms behind a proper **line sort …
JavaScript Keyboard Events: key vs code vs keyCode Explained
I was building a keyboard shortcut feature recently and kept mixing up event.key, event.code, and event.keyCode. So I built an online tool to…
Structured Data in Practice: Building a JSON-LD Generator for SEO
When working on website SEO, you often hear about “structured data”. Simply put, it’s a machine-readable format to tell search engines: this is a p…
JSON to SQL Batch Insert: From Escape Traps to Performance Optimization
Recently worked on a data migration project, importing API JSON data into MySQL. Seemed simple at first—just map JSON fields to SQL statements, rig…
JSON Path Finder: From Tree Traversal to Path Generation
Debugging a deeply nested API response recently, I needed to quickly locate the JSONPath of specific fields. Counting levels manually was painful, …
JSON Deep Merge: From Object.assign to Recursive Merge Algorithms
When merging config files, I discovered that Object.assign and the spread operator ... only perform shallow copies. Nested properties get repla…