dowjones / gulp-bundle-assets

Create static asset (js, css) bundles from a config file: a common interface to combining, minifying, revisioning and more
MIT License
133 stars 36 forks source link

Allow for all media types in css links #28

Closed csherland closed 10 years ago

csherland commented 10 years ago

Had some issues with media queries and tracked it down to this. Print queries were not evaluating as a result of this.

i.e.

@media print {
   ...
}

Might be nice to have something more configurable here in the future, so that a user can specify the desired media type for the sheet. Something along the lines of

module.exports = function (path, media) {
    return "<link href='" + path + "' media='" + media + "' rel='stylesheet' type='text/css'/>";
};

Although media='all' should be sufficient for now.

chmontgomery commented 10 years ago

:+1: looks great, thanks!

chmontgomery commented 10 years ago

can you fix the tests?

csherland commented 10 years ago

Whoops! Fixed the tests. Looks like the build passes now.

chmontgomery commented 10 years ago

squashed and merged as https://github.com/chmontgomery/gulp-bundle-assets/commit/ba95b29055ad3183d6b94d422176e005db563ea8

Thanks for the contribution! You're the first on the contributors list :smile: