-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LESS don't work if has included unrecognized .less file. #1534
Comments
less 1.5.0 beta is no longer showing nice error messages for less files it cannot find? |
Yes. And not only less 1.5.0, less 1.4.1 too |
ok.. well
|
I am not use bracket in my project. I made a mistake just in issue |
.. and number 2, e.g. I cannot reproduce? browser or node? are you doing anything weird? |
I think that what he means is: if you try to include a css-file that doesn't exist, the compiler moves on and just ignores it. If you do the same with a less file, you get an error telling you the file can't be found. |
But a css file is kept verbatim and turned into an imort.. so depending on |
Ok. i recorded screencast http://youtu.be/x0ZssAHHjZI. Sorry for my English |
So, the problem is that when a .less-file is not found, LESS.js does not show an error? |
Yes. I think error must be, bacause the strange thing is that everything works with unrecgnized .css |
can you reproduce it with your code on less2css.org ? because with simple examples it works, so it must be something in your less file or something wrong with your setup. |
Sorry for bad feedback. Download this demo please http://yadi.sk/d/jhGUPRXsAsMZg, because i am not understand how i can reproduce it on less2css.org |
I downloaded and tried the demo. Reported issue is that less.js returns an error if imported .less file is not found. Imported css is treated spit out to output as is. I'm closing the issue, since this is working as it should. Imports of files with .css suffix are assumed to be css imports and less.js keeps them unchanged. Imports of files with .less suffix are assumed to be commands for compiler and files are supposed to be available. Workaround: if you want an import of .less in the output, use
If you want .less compiled if present and kept as is if not present, add +1 to the option import directive #2145 which covers that functionality. Approximate content of of the demo: If you do following:
less.js spits out following:
If you do following:
less.js spits out error:
|
We have one file: index.less. If we write in index.less
@import ("included.css"); // unrecognized .css file
that LESS work correctly. But if write@import("included.less"); // unrecognized .less file
that LESS don't work and don't display error.I test it on LESS 1.4.1 and 1.5.0
Thanks a lot.
The text was updated successfully, but these errors were encountered: