LESS CSS Comments in the right place

I am using LESS CSS for WordPress Theme development. I have just noticed that when I compile the LESS files to CSS all of the comments placed inside LESS file are added to the top of the CSS file (and not on the right line)… is there any way to avoid this? I am using Less for mac as a compiler also tried the simpLess but the same problem occurs.

Related posts

Leave a Reply

1 comment

  1. Whilst not ideal, and certainly against convention, I place my comments inside the style definition.

    eg:

    .style {
    
        /* Comment for .style */
        ...style definition...
    
        .inner-style {
            /* Comment for .inner-style */
            ...style definition...
        }
    }