Skip to content
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

Comments not preserved in referenced includes #2675

Closed
betaorbust opened this issue Aug 28, 2015 · 0 comments · Fixed by #2677
Closed

Comments not preserved in referenced includes #2675

betaorbust opened this issue Aug 28, 2015 · 0 comments · Fixed by #2677

Comments

@betaorbust
Copy link
Contributor

Problem

When a file is included with (reference) in-property comments are stripped out. This breaks the only workaround to #2674.

Bug example

Input

// test.less
@import (reference) 'imported-file.less';
.my-test{
    .my-mixin();
}
// imported-file.less
.my-mixin(){
    color: red /* comment that should be there */;
}

Output

.my-test {
  color: red;
}

Expected Output

.my-test {
  color: red /* comment that should be there */;
}
betaorbust added a commit to betaorbust/less.js that referenced this issue Aug 30, 2015
As described in less#2675 in-value comments are not preserved in referenced rules.

This patch adds reference marking to nodes below rules and expressions if markReferenced is available.
betaorbust added a commit to betaorbust/less.js that referenced this issue Aug 31, 2015
As described in less#2675 in-value comments are not preserved in referenced rules.

This patch adds reference marking to nodes below rules and expressions if markReferenced is available.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant