JSONPath Filter Expressions: Operators, Examples and Gotchas
How [?(...)] filters work: comparisons, && and ||, testing for a property, comparing against another path, and the cases where implementations differ.
Blog
Developer tooling, security, web performance and search, written when something turned out to be more interesting than expected.
How [?(...)] filters work: comparisons, && and ||, testing for a property, comparing against another path, and the cases where implementations differ.
There is no ideal keyword density. How the number is calculated, why tools disagree, and the one job it does well: catching accidental overuse.
755 is for directories and programs, 644 for ordinary files. How the three digits are built, why those two are the defaults, and the find command to fix a tree.
Commit .env.example and never .env. What each file is for, what belongs in the template, the .gitignore lines that work, and what to do after a leak.
Anyone can read a JWT's payload with no key. What is actually inside a token, why decoding proves nothing, and the checks that make a token trustworthy.
Screen readers can read #socialmediatips as one run-on word. Why capitalising each word fixes it, camelCase versus PascalCase, and where the advice stops.
White text fails contrast on most mid-tone backgrounds. Measured ratios for 15 common UI colors, why black often wins, and how small a fix can be.
Measured on a real stylesheet, alone and together. Comments turned out to matter more than whitespace, and Brotli beat gzip by about 15 percent.
The gap is 5 hours most of the year and 4 for a few weeks, because US and UK daylight saving changes fall on different dates. The 2026 and 2027 windows.
A Unix timestamp is one number with no time zone. How to tell seconds from milliseconds, the bugs that mixing them causes, and what the 2038 problem is.
A JSON sample is one snapshot, so a generated interface is a guess. What converters get wrong with null, missing fields, empty arrays and strings.
JSONPath selects values and is built into many tools. jq transforms JSON on the command line. The same queries in both, and how to choose.
JSON objects have no order, so a text diff reports changes that are not changes. How to sort keys first, what still differs, and three ways to do it.
Both can mean a space, in different places. When %20 is right, when + is, why a literal plus becomes a space, and the base64 bug it causes.
How to read a cron expression, why 0 0 13 * 5 is not Friday the 13th, why */7 is uneven, and the time zone and escaping mistakes that break scheduled jobs.
In YAML 1.1, NO becomes false. Tested YAML 1.1 and 1.2 results for yes/no, octal, 22:22, version numbers and merge keys, and how to convert safely.
The order of lines does not decide it. The longest matching rule wins, a tie goes to Allow, and the group is chosen first. Worked examples you can test.
Most online PDF and image tools send your file to a server. Three browser checks that show whether one does, and the catch that can fool you.
Which user-agent names to use for OpenAI, Anthropic and Google AI crawlers, the difference between training and search bots, and a robots.txt you can paste.
UTM tags are easy to add and easy to get wrong. A simple naming convention, the mistakes that split your reports, and where tagged links should not go.
Photos that look fine in your gallery land sideways in a PDF because of the EXIF orientation tag. What the tag is, why PDF tools ignore it, and four fixes.
Merging does not compress anything, so a merged PDF is at least the sum of its parts. What actually makes a PDF heavy, how to find it, and what shrinks it.
Structured data does not boost rankings by itself. What it actually does, which types are worth adding, and why FAQ markup stopped paying off for most sites.
Most online PDF mergers upload your files. How merging works locally in the browser, how to verify nothing leaves your device, and where it falls short.
A link preview is built from a few meta tags and one image. What each platform reads, what the image needs, and why a fix often does not show up.
robots.txt controls crawling, not indexing. What the file can and cannot do, how rules are matched, and the mistakes that quietly block or expose a site.
The answer depends far more on which hashing algorithm protects the password than on its length or symbols. Here is the actual math, worked through for both.
JSON looks like a JavaScript object literal, so people assume they behave identically. Undefined, dates, key order and duplicate keys all say otherwise.
A QR code is just a wrapper around a URL, with no way to preview the destination before you scan. That single gap is the entire attack, and it has a name now.
Data URIs let you embed an image directly in HTML or CSS as Base64 text. It works, it's overused, and it makes some pages slower rather than faster.
Base64 is an encoding, not a cipher. It has no key, protects nothing, and is trivially reversible — here is what it is actually for.
UUIDs are said to be unique enough to ignore the possibility of a collision entirely. Here is the birthday-paradox math behind that claim, worked out in full.
Requiring a capital letter, a digit and a special character feels like it should help. NIST dropped the recommendation, because in practice it mostly doesn't.
Scanning a QR code to join WiFi works because of a plain-text string format your phone's camera already understands. Here is exactly what's inside it.
Four common ways to identify a row, and the trade-offs that actually distinguish them: size, coordination, what they leak, and whether others use the format.
Google replaces meta descriptions on roughly two thirds of queries. Here is when it happens, why, and the cases where your description still decides the click.
A JSON document can parse perfectly and still have the wrong shape. Here is the difference between syntax and schema validation, and when you need both.
Base64 padding explained. Why strings end in one or two equals signs, or none at all, the bit-level reason, and when it is safe to drop the padding.
Random v4 UUIDs scatter writes across your index and cause page splits. Version 7 sorts by time and fixes it, without giving up global uniqueness.
Modern browsers can decode, resize and re-encode images locally using Canvas. How it works, which quality setting to pick, and where the approach breaks down.