Created
March 9, 2013 00:34
-
-
Save branquito/5121744 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
VIM regex | |
Strip class attributes from HTML tags, including those spanning over multiple lines | |
Change `class` word for anything else you want to strip.. | |
:%s/<\s*\(\w*\)\s*class[^>]*>\([^<]\_.\{-}\)<\/.*>/<\1>\2<\/\1>/gc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment