Skip to content

Instantly share code, notes, and snippets.

@jimhigson
Last active December 31, 2015 15:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jimhigson/8005597 to your computer and use it in GitHub Desktop.
Save jimhigson/8005597 to your computer and use it in GitHub Desktop.
regex for cleaning up inkscape markup - most SVGs should display the same if matches are removed.
// this regular expression detects most of the Inkscape markup in an SVG which can be safely removed for delivery to a browser
(style|(inkscape|sodipodi):[^=]+)="[^"]*"|id="(path|rect|layer|defs|g)[\d-]+"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment