Releases: 11ty/eleventy-utils
Eleventy Utils v2.0.7
Eleventy Utils v2.0.6
- Adds
createHashSync
andcreateHashHexSync
functions (identical use to async functionscreateHash
andcreateHashHex
respectively). These functions automatically swap betweennode:crypto
, the web standard WebCrypto API, and an inline script option in all other environments. - Adds Node v24 to CI test suite
import { createHashSync, createHashHexSync } from "@11ty/eleventy-utils";
const base64UrlHash = createHashSync("This", "is", "an", "arbitrary", "string.");
const hexHash = createHashHexSync("This", "is", "an", "arbitrary", "string.");
Eleventy Utils v2.0.5
Adds createHashHex
export for hex
hashes, similar to the createHash
function which returns base64
hashes. Currently hex hashes are used by the Fetch plugin.
import { createHashHex } from "@11ty/eleventy-utils";
const hash = await createHashHex("This", "is", "an", "arbitrary", "string.");
Full Changelog: v2.0.4...v2.0.5
Eleventy Utils v2.0.4
- Fix bug with
Buffer
orUint8Array
passed tocreateHash
(when using WebCrypto API) — for Eleventy Image
Full Changelog: v2.0.3...v2.0.4
Eleventy Utils v2.0.3
Adds support for multiple arguments to new createHash
utility to pass multiple pieces of content to the hashing function (backwards compatible with Node’s support for multiple .update()
calls).
import { createHash } from "@11ty/eleventy-utils";
const base64hash = await createHash("This", "is", "an", "arbitrary", "string.");
Full Changelog: v2.0.2...v2.0.3
Eleventy Utils v2.0.2
Adds new createHash
async function to generate base64 hashes from string content (used in Bundle and Image plugins), compatible with WebCrypto (Node 19+) and falls back to use node:crypto
in other cases.
import { createHash } from "@11ty/eleventy-utils";
const base64hash = await createHash("This is an arbitrary string.");
Full Changelog: v2.0.1...v2.0.2
Eleventy Utils v2.0.1
- Adds new DateCompare utility (for use in Fetch and Import utilities) to compare dates with string durations (e.g.
"*"
,"24h"
,"1y"
)
Full Changelog: v2.0.0...v2.0.1
Eleventy Utils v2.0.0
- BREAKING: Node 18+
- Removes
normalize-path
internal dependency (now a zero dependency package) - docs: JSDoc tweaks. by @Zearin in #4
- refactor,test: Rewrite tests using Node test runner by @Zearin in #2
- Shipping with
@11ty/eleventy@3.0.1
and3.0.1-alpha.1
11ty/eleventy#3595
Full Changelog: v1.0.3...v2.0.0
Eleventy Utils v2.0.0-alpha.2
- BREAKING: Node 18+
- Removes
normalize-path
internal dependency. - docs: JSDoc tweaks. by @Zearin in #4
- refactor,test: Rewrite tests using Node builtins by @Zearin in #2
Full Changelog: v1.0.3...v2.0.0-alpha.1