Reputation: 1179
This scenario was testet in Visual Studio 2012 with the Web Essentials extension.
Filesystem:
root\folder1\subfolder1\styles\main.less
root\folder2\subfolder1\subfolder2\styles\fear.less
main.less:
@import "../../../folder2/subfolder1/subfolder2/styles/fear.less";
Compile Error:
LESS: Couldn't load folder2/subfolder1/subfolder2/styles/fear.less (404)
Is it possible that LESS does not support multiple subdirectories?
Upvotes: 4
Views: 1007
Reputation: 1179
Well now, I got it! @Jeff's answer brought me to the following:
@import "..\..\..\folder2\subfolder1\subfolder2\styles\fear.less";
It also works for variables. You have to declare the whole filename including the extension. No leading slash and only backslashes.
Upvotes: 0
Reputation: 440
This is apparently a known bug/issue. In the meantime you can replace the forward slash in the import path with a backslash. That worked for me.
Upvotes: 3