I'm going thru Michael Hartl's Ruby on Rails tutorial and, like him, using TextMate as my editor. Today, in chapter 3 of his tutorial, I saw him do something in TextMate I've not seen done before:
As he types a tag in a file called "whatever.html", the tag dynamically updates and creates a corresponding ending tag. So, as an example, if he's typed <ht
, then TextMate automatically creates <html></html>
, apparently on the fly.
I've found the keystrokes to autocomplete a tag, but this is a little different. Any ideas how this is being done?
opt/alt⌥esc⎋ will autocomplete the tag name, ctrl⌃< or ctrl⌃shift⇧, will transform it into open and close tags.
Go to Bundles -> HTML -> Insert Tag menu to find other tag insertion keystrokes.
Check Bundles -> Html for all the different keystrokes you can use. I'm guessing this could be the Ctrl-< keystroke.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With