elastic / elastic/docs-content
Consolidate URL field formatter template variable docs in data-views.md
- Dominant language
- No language data
- Stars
- 47
- Forks
- 261
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 130
Description
## Problem
In `explore-analyze/find-and-organize/data-views.md`, the URL field formatter explanation is duplicated verbatim three times, under **String field formatters**, **Date field formatters**, and **Number field formatters**. Every change to it is a three-way edit with drift risk.
The template variables are also spread across separate prose paragraphs, and the page never states which variable works in which template. One behavior difference is currently undocumented and surprising: `{{value}}` is URL-encoded in a URL template but passed through raw in a label template.
Verified against `src/platform/plugins/shared/field_formats/common/converters/url.tsx` in `elastic/kibana` (the locals passed by `formatUrl()` and `formatLabel()`):
| Variable | URL template | Label template |
|---|---|---|
| `{{value}}` | URL-encoded | Raw, not encoded |
| `{{rawValue}}` | Raw | Raw |
| `{{url}}` | Not available | The formatted URL |
A variable that isn't in a template's locals renders as an empty string rather than failing, so using the wrong variable fails silently.
## Proposal
1. Extract the shared URL formatter explanation into `_snippets/` and include it in all three sections.
2. Replace the scattered variable paragraphs with a single table (variable | URL template | label template), using inline `applies_to` in cells for version-scoped entries.
3. Add one worked example of a Kibana app URL template, in the String section only. `explore-analyze/visualize/legacy-editors/tsvb.md` has a good model.
4. Cross-link the Rison definition already in `explore-analyze/dashboards/drilldowns.md`.
5. While in the file: the four existing inline `applies_to` badges (`stack: ga 9.2` and `stack: ga 9.4`) use the closed form. Switch them to the preferred open-ended `9.2+` / `9.4+`, and check whether each needs an explicit `serverless:` key given the page is `serverless: ga`.
Re-verify the variable list against `url.tsx` at HEAD before drafting, since the set of supported variables may have changed.
## Files
- `explore-analyze/find-and-organize/data-views.md`
TriageBot — Needs refinement
### 2026-08-12
**Type:** enhancement
**Section check:**
- ❌ Required outcome/definition of done is missing; the issue describes the problem and proposal, but not the final content shape.
**Ambiguity / scope notes:**
- None blocking beyond the requested rewrite work.
**Cross-references:**
- All checked links are valid or not relevant to triage.
**Next step:** Run `/triage` again after updating the description.
> Generated by [Gh Aw Issue Triage](https://github.com/elastic/docs-content/actions/runs/31585034980) for #7921 · gpt50mini · 6.09 AIC · ⌖ 1.67 AIC · ⊞ 28.6K · [◷](https://github.com/search?q=repo%3Aelastic%2Fdocs-content+is%3Aissue+%22gh-aw-workflow-call-id%3A+elastic%2Fdocs-content%2Fgh-aw-issue-triage%22&type=issues)
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.