Skip to content

Conversation

azt3k
Copy link

@azt3k azt3k commented Jul 2, 2014

This gives enough flexibility to selectively include or exclude external style sheets. The main reason I needed this was to provide a workaround for bypassing an external style sheet with @font-face declarations.

<link id="google-font" href='http://fonts.googleapis.com/css?family=Open+Sans:400' rel='stylesheet' type='text/css'>
<link href='css/styles.css' rel='stylesheet' type='text/css'>
html = File.read 'path/to/file.html'
html = InlineStyle.process html, stylesheets_path: 'src', ignore: '#google-font'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant