CodeSleeve / asset-pipeline

This Laravel 4 package provides a very simple and easy to use asset pipeline. It was heavily inspired by the Rails asset pipeline. We make use of the wonderful Assetic package to help with pre-compliation!
http://www.codesleeve.com
MIT License
491 stars 53 forks source link

Semicolon at the end of stylesheets #145

Closed alangvara closed 10 years ago

alangvara commented 10 years ago

The problem comes on production environment when it concatenate the stylesheets, it puts a semicolon at the end of every file, which its ok for javascript but in css breaks the layout.

kdocki commented 10 years ago

@alangvara what version of pipeline are you using?

kdocki commented 10 years ago

@alangvara this should not happen unless asset pipeline thinks your css is a javascript mime type (have you customized your config? and if so you might want to double check your mime types).

alangvara commented 10 years ago

I'm using v2.0.0, and i have the default configs, these are the important ones i think:

'mimes' => array( 'javascripts' => array('.js', '.js.coffee', '.coffee', '.html', '.min.js'), 'stylesheets' => array('.css', '.css.less', '.css.scss', '.less', '.scss', '.min.css'), ),

'filters' => array( '.css' => array( new Codesleeve\AssetPipeline\Filters\URLRewrite(App::make('url')->to('/')), new EnvironmentFilter(new Codesleeve\AssetPipeline\Filters\CssMinFilter, App::environment()), ), ),

i started a new project to check and the problem persist in version 2.0.0 but in 1.5 works ok.

kdocki commented 10 years ago

See if the problem still exists in dev-master. I think I fixed this already... also I am fixing to push out a new version tagged 2.0.1 ...

chrisnew commented 10 years ago

Any updates? I encounter the same issue.

alangvara commented 10 years ago

Works great with the last 2.0.1 release, thank you man.

kdocki commented 10 years ago

@chrisnew are you on 2.0.1?

chrisnew commented 10 years ago

@kdocki yep, thank you! It works now! :) Rather off topic: We only stumbled over commit CodeSleeve/sprockets#a84666e5a65495c1451986e7944f4eda90b3e829 requiring now a space between "//=" and directive. We had a lot of "//=require ..." statements. ;)