You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 9, 2019. It is now read-only.
lesscss-java throws a LessException with the error message "Syntax Error on line 9" when the error is really on line 3.
Looking through the source code, it appears that this behavior is the result of concatenating the parent file with all of its imports in LessSource.resolveImports() (LessSource.java, line 147, which gets fed in to LessCompiler.java, line 302).
Is there a technical reason for this design choice? It would be really nice if we could let less.js take care of resolving imports and reporting the correct line number for syntax errors.
When compiling a file that
@import
s another LESS file,lesscss-java
reports the wrong line number for syntax errors.For example, suppose I have the following files:
parent.less
include.less
lesscss-java
throws aLessException
with the error message "Syntax Error on line 9" when the error is really on line 3.Looking through the source code, it appears that this behavior is the result of concatenating the parent file with all of its imports in
LessSource.resolveImports()
(LessSource.java, line 147, which gets fed in to LessCompiler.java, line 302).Is there a technical reason for this design choice? It would be really nice if we could let
less.js
take care of resolving imports and reporting the correct line number for syntax errors.(Credit goes to micmcg for pointing this out.)
Thanks!
The text was updated successfully, but these errors were encountered: