title: setting a dynamic data attribute on flask wtforms jinja select
body: <p>Have a flask wtforms select field and trying to incorporate htmx ajax call, which has dashes in data attributes so I found a solution on SO like the following:</p>
  <pre><code>{{ form.dia(class=&quot;form-select&quot;, **{'hx-post': &quot;/pulleys/{{pulley_id}}/hub_type&quot;, 'hx-target': &quot;#hub-shaft-selection&quot;, 'hx-swap': &quot;innerHTML&quot;}) }} 
  </code></pre>
  <p>but the {{pulley_id}} doesn't get parsed by the template, I guess it's already inside another {{ }}.
  Is there a way to build the dynamic part as shown above so it ends up as</p>
  <pre><code>'hx-post'=&quot;/pulleys/1/hub_type&quot;
  </code></pre>
  <p>when fully rendered for pulley_id=1</p>