MCPcopy Create free account
hub / github.com/Effect-TS/effect / fromFileWeb

Function fromFileWeb

packages/effect/src/unstable/http/Etag.ts:90–92  ·  view source on GitHub ↗
(file: Body.HttpBody.FileLike)

Source from the content-addressed store, hash-verified

88}
89
90const fromFileWeb = (file: Body.HttpBody.FileLike) => {
91 return `${file.size.toString(16)}-${file.lastModified.toString(16)}`
92}
93
94/**
95 * Layer that provides a `Generator` which produces strong ETags from file size

Callers

nothing calls this directly

Calls 2

toStringMethod · 0.65
syncMethod · 0.45

Tested by

no test coverage detected