Blog Archives
Textmate command for copying last selector in CSS
I recently was crafting some CSS, but I kept running into places where I would have this situation:
#someDiv li a:hover { color: #fff; }
But I would want to also add an a:active and an a:focus. Unfortunately that means I would have to copy #someDiv li and paste it. This is why Textmate commands were created.
So I created a command for copying the last selector on the line and guessing what you want to change. Now I can press ctrl-c and presto, the last selector is inserted as a snippet.
Posted: November 04, 2009 @ 18:55
Comments
No comments have been added