Merge pull request #1779 from bhollis/minify-js

Minify inline JS when there are other attributes.
feature/manifest
Thomas Reynolds 2016-01-25 10:11:09 -08:00
commit 24ef35026e
1 changed files with 1 additions and 1 deletions

View File

@ -112,7 +112,7 @@ class Middleman::Extensions::MinifyJavascript < ::Middleman::Extension
# Only compress script tags that contain JavaScript (as opposed to
# something like jQuery templates, identified with a "text/html" type).
if first.include?('<script>') || first.include?('text/javascript')
if !first.include?('type=') || first.include?('text/javascript')
first + minify(inline_content) + last
else
match