Skip to content

Instantly share code, notes, and snippets.

@traviskroberts
Created April 16, 2012 15:05
Show Gist options
  • Save traviskroberts/2399340 to your computer and use it in GitHub Desktop.
Save traviskroberts/2399340 to your computer and use it in GitHub Desktop.
TextMate snippet for Bootstrap control group.
<div class="control-group">
<%= f.label_tag :${1:name}${2:, "${3:Name}"}, :class => "control-label${4: required}" %>
<div class="controls">
<%= f.${5:text_field}, :${1}${6:, :class => "${7:span5}"} %>
</div>
</div>
@mattslay
Copy link

See this gist for a helper method that will eliminate so much hard-coding in your views:

https://gist.github.com/2505143

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment