postcss-less: Detached ruleset processing returns incorrect selector

  • Node Version: v6.8.0
  • NPM Version: 4.6.1
  • postcss-less Version: 1.1.0

LESS

.test({
	.hello {
		.test {
		}
	}

	.fred {
	}
})

JavaScript

postcss()
  .process(lessText, { syntax })
  .then(function (result) {
    console.log(result.root.nodes[0].selector)
});

Expected Behavior

Expected selector to not include mixin parameter

Actual Behavior

selector includes entire input less text (including parameter)

How can we reproduce the behavior?

Using code above

Note: It’s possible I do not understand how the parsed output is supposed to look for the provided less content.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Reactions: 1
  • Comments: 16 (7 by maintainers)

Commits related to this issue

Most upvoted comments

@ntwb Had too many issues with npm@5 to jump back in just yet. Working with shared codebase and often checking out older revisions for testing led to many nightmares. I understand it’s fixed now, but once bitten, twice shy. But, I could update my node to something more recent!