EnvelopeFlow.Templates
0.1.0-alpha.3.1
dotnet add package EnvelopeFlow.Templates --version 0.1.0-alpha.3.1
NuGet\Install-Package EnvelopeFlow.Templates -Version 0.1.0-alpha.3.1
<PackageReference Include="EnvelopeFlow.Templates" Version="0.1.0-alpha.3.1" />
<PackageVersion Include="EnvelopeFlow.Templates" Version="0.1.0-alpha.3.1" />
<PackageReference Include="EnvelopeFlow.Templates" />
paket add EnvelopeFlow.Templates --version 0.1.0-alpha.3.1
#r "nuget: EnvelopeFlow.Templates, 0.1.0-alpha.3.1"
#:package EnvelopeFlow.Templates@0.1.0-alpha.3.1
#addin nuget:?package=EnvelopeFlow.Templates&version=0.1.0-alpha.3.1&prerelease
#tool nuget:?package=EnvelopeFlow.Templates&version=0.1.0-alpha.3.1&prerelease
EnvelopeFlow.Templates
Templates use literal {variable} substitution, never executable expressions. HTML values are encoded, titles reject line breaks, and the complete serialized result is checked against the caller's provider byte limit. Resolve an exact version with requested locale, parent locale and explicit default fallback. Code- and JSON-file-backed resolvers are examples; replace the resolver or renderer independently. Files are application-selected paths and never derived from recipient input. Attachments remain explicit email-transport inputs, never template file reads.
Source fields, layout content, recipient values and raw prepared payloads must be well-formed Unicode without NUL. Validation precedes parsing/caching, HTML encoding, publication freezing and hashing, so encoding cannot silently change accepted content. Valid surrogate pairs, literal replacement characters, tabs/line breaks and existing length limits remain supported; escaped NUL inside an already serialized JSON payload remains exact. Prepared context/publication digests require 64 ASCII hexadecimal characters; upper/lowercase are preserved exactly through replay and storage.
Optional ITemplateRegistry supports validated drafts, revision-CAS edits/archive, immutable publication manifests and explicit pointer selection/rollback. Exact-version resolution never consults that pointer. Idempotent publication receipts preserve the original result after a lost acknowledgment; layout name/version bytes remain immutable across publications in a scope. Memory is a development example; select the separate PostgreSQL package or a custom atomic adapter for durability.
TemplateComposition previews the same declarative content used at admission. Layouts use one [[body]] slot per matching text/HTML field and explicit versioned [[partial:alias]] references. Limits are eight graph levels, 64 layouts, 16 partials per layout, 128 visits per expansion and one MiB per publication. Missing/cyclic/wrong-channel dependencies and excessive expansion fail before rendering. Values are substituted after composition and HTML encoded. Preview is not HTML sanitization; complete provider-envelope validation requires the application callback.
Reference registries retain at most 128 drafts/publications and 512 publish receipts per full scope, within an eight-MiB document. Draft archive uses CAS; published artifacts/layouts/receipts remain retained and capacity fails explicitly. No cleanup job or HTTP/editor surface is supplied. The separate delivery integration freezes target bytes under stable preparation keys; live policy remains authoritative. Content and variables are private application data, redacted from record diagnostics.
Opt in per immutable MessageTemplate with Syntax = TemplateSyntax.Localized. SafeLocalizedTemplateRenderer supports {name}, {n, number, N2}, {when, date, short|long|iso}, {n, plural, =0 {Empty} one {One} other {Many}} and {kind, select, known {Known} other {Other}}. Branches require other; recipient values remain literal, and only selected branches render. Number input is an exactly representable bounded invariant decimal; excess precision refuses instead of rounding the branch operand. Number formats are G, N/F with 0–4 decimals, P/C with 0–2; currency requires a specific culture. Date input is ISO-8601, normalized to UTC before culture-specific formatting. Plurals pin Unicode CLDR 49 cardinal rules for en/de/es/it/fr/ru/uk/pl/ar/ja/zh/ko, retaining visible fraction operands and the fr/es/it million category. Other plural locales require a custom renderer. This is a declared safe subset: exponent/compact notation (CLDR e is zero), ordinals/ranges, ICU offsets, # replacement, arbitrary expressions and external access are excluded.
Localized syntax retains the same body/channel/header constraints and HTML value encoding. Validation visits every branch before publication; bounds are eight nested levels, 1,024 nodes per field, sixteen branches per token, 262,144 characters per field, 1,000 variables and one MiB aggregate input values. Rendering enforces a complete serialized provider byte limit, including multibyte text and HTML expansion. Default literal syntax omits the additive JSON field and retains existing bytes. Code/file resolution, immutable publication/layout composition and frozen delivery preparation retain the chosen syntax, exact version and resolved locale; a pointer update never rerenders queued work. The default composition preview selects the matching supplied renderer; custom renderers remain replaceable.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net11.0 is compatible. |
-
net11.0
- EnvelopeFlow.Core (>= 0.1.0-alpha.3.1)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on EnvelopeFlow.Templates:
| Package | Downloads |
|---|---|
|
EnvelopeFlow.Templates.Delivery
Recoverable frozen template rendering and stable delivery admission. |
|
|
EnvelopeFlow.Templates.Stores.Postgres
Optional durable scoped template publication and frozen preparation stores. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.0-alpha.3.1 | 50 | 11/22/2026 |
| 0.1.0-alpha.2.1 | 75 | 11/9/2026 |