DRY attribute selection
<p>Say I have an element on the page:</p>

<pre><code>&lt;div data-name='foo'&gt;
</code></pre>

<p>What's the best way to get the attribute value? Is there anything more DRY than <code>$('[data-name]').attr('data-name')</code> or <code>$('[data-name]').data('name')</code>?</p>
