title: Using hyphenated HTML attributes in MVC
body: <p>Consider the following valid razor HTML helper code:</p>
  
  <pre><code>@Html.TextBoxFor(m =&gt; m.Name, new { @class = "form-control", placeholder="Select..." })
  </code></pre>
  
  <p>However, there are some libraries that I'm using, that uses hyphenated attributes such as this:</p>
  
  <pre><code>&lt;select class="form-control select2me" data-placeholder="Select..."&gt;
  </code></pre>
  
  <p>When I try to do this:</p>
  
  <pre><code>@Html.TextBoxFor(m =&gt; m.Name, new { @class = "form-control", data-placeholder="Select..." })
  </code></pre>
  
  <p>I get this error:</p>
  
  <pre><code>Invalid anonymous type member declarator. Anonymous type members must be declared with a member assignment, simple name or member access.
  </code></pre>
  
  <p>How can I use hyphenated attributes in razor synax?</p>