JavaScript: The Full Guide to Modern Development Logic
Comprehensive resources covering the entire JavaScript ecosystem, from foundational syntax and logic to advanced runtime execution and modern web patterns.
Content tagged javascript
Snippet:First N Matches from Any Iterable with
filter()andtake()Get the first N matches and stop reading.Return the first N matches from any iterable with Iterator.from(), filter() and take(), stopping as soon as it has enough, even on infinite sequences.Tutorial:Iterator Helpers: Lazy Pipelines over Any Iterator
Map, filter and take over any iterator, lazily.Use ES2025 iterator helpers (map, filter, take, drop, flatMap, reduce, Iterator.from) to build lazy pipelines over generators, Sets, Maps and infinite sequences.Tutorial:JavaScript Iterator
chunks(),windows(),includes()andjoin()Group, window, search and join any iterator natively.Use JavaScript's new iterator chunks(), windows(), includes() and join() for batching, moving averages and calendar rows, with edge cases and fallbacks.Post:Trusted Types and
eval: The Dynamic Code Brand Checks ProposalGuard eval and new Function with Trusted TypesWhy eval and new Function are risky, how Trusted Types and CSP contain them, and what the Stage 3 Dynamic Code Brand Checks proposal changes. Not in ES2027 yet.Snippet:Bytes to Hex and Back with
Uint8Array.fromHex()andtoHex()Convert bytes to hex and back without padStart loops.Encode bytes as hex with ES2026's Uint8Array toHex(), decode with fromHex() and setFromHex(), with SHA-256 digests, colours, error cases and a padStart fallback.