SemText

Reference · SemText · Knowledge & documents

<sem-guard-rails>

SemText element

You wrap sem-guard-rail children in it. The collection sorts nothing and invents nothing — the rails you wrote, in the order you wrote them.

A collection of guard rails. You wrap sem-guard-rail children in it. The collection sorts nothing and invents nothing — the rails you wrote, in the order you wrote them. collection qualifier drawn into the label chrome (display-only sugar). (per entry): one of `info` (default), `warn`, `block` — selects the rail color; display-only sugar, extraction is identical under every severity. (per entry): `string` — free token naming where the rule applies; drawn into the entry's label chrome. per the global attribute catalog (conventions.md §2) per the global attribute catalog (conventions.md §2)

Example

sem-guard-rails.html
source
1 <sem-guard-rails id="gr-api" kind="api">
2 <sem-guard-rail severity="block" scope="public endpoints">
3 Never return raw provider errors; wrap them in the error envelope.
4 </sem-guard-rail>
5 <sem-guard-rail severity="warn">
6 Pagination defaults to 50 items — page explicitly in production.
7 </sem-guard-rail>
8 </sem-guard-rails>
render
No shipped runtime for this element — the authored example renders as plain HTML.

Source: spec/schema/sem-guard-rails.md