A mapping of radio checkbox values to human-readable labels
Options which configure how select options are generated by the helper
Generated HTML safe for rendering into a Handlebars template
let choices = {a: "Choice A", b: "Choice B"};
let value = "a";
The template HTML structure
<select name="importantChoice">
{{selectOptions choices selected=value localize=true}}
</select>
The resulting HTML
<select name="importantChoice">
<option value="a" selected>Choice A</option>
<option value="b">Choice B</option>
</select>
let choices = {"Choice A": "a", "Choice B": "b"};
let value = "a";
The template HTML structure
<select name="importantChoice">
{{selectOptions choices selected=value inverted=true}}
</select>
A helper to create a set of <option> elements in a <select> block based on a provided dictionary. The provided keys are the option values while the provided values are human-readable labels. This helper supports both single-select and multi-select input fields.