Search code examples
csslessdotless

Using a variable in @import statement - DotLess


I'm am using DotLess v1.4 and I would like to do the following:

// Variables
@Utilities-path: "../../Utilities";

@import "@{Utilities-path}/bacon.less";

When I do this I get a file not found error.

File Not Found while parsing: You are importing a file ending in .less that cannot be found.

If I do this it works correctly.

@import url('../../Utilities/bacon.less');

As far as I'm aware this was added to Less in version 1.4, so I assumed it would work in the latest version of DotLess.

Does anyone know if this feature is available and if so what I am doing wrong?


Solution

  • This is feature is not available in DotLess v1.4. Version 1.4 does not mean that is using the equivalent version of LESS.