Less file isn't recompile when @import are not in the same folder than less.sources #2

Calvein opened this Issue Oct 26, 2012 · 1 comment


None yet
2 participants

Calvein commented Oct 26, 2012

I have a less file in ./web/css/bootstrap.less and the CSS in the same folder : ./web/css/bootstrap.css

The problem is that my bootstrap.less file @import files that are not in the same directories as it, but the targetNeedsRecompile method only check less files that are in the same directory of the files specifies in the less.sources option but it should check the @import too.


darklow commented Oct 26, 2012

Unfortunately there is no way how ff-silex-less-provider could know all @imports, unless it looks at the content of .less files, but since they can be chained it is not so easy task and i don't think provider should do it at all. Lessphp library also doesn't provide such a feature to list all the imports.

That leaves us only one option. Change the config so that you can specify additional files or directories where to look for changed files. I need to think on config format a bit.

Is you are on a UNIX server, as a temporary fix you can create alias.

@Calvein Calvein closed this Aug 21, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment