less / less/less-docs

`default()` guard should be documented / mentioned with mixin documentation

Open
#617 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Less
Stars
680
Forks
442
PR merge metrics
No merged PRs in 30d

Description

The default mixin guard is documented, but it's somewhat buried in the functions section.

I think, since the default function is actually not really a function, and is instead more "function-like", it would make more sense to move it to mixin documentation, with maybe a brief reference in the functions section.

To add

I think what could be added to this documentation is a little more explanation of when a default function applies, in relation to overloading. That is, it appears that default() is only applied once mixins have been filtered for arity.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the existing default() entry in the functions section and compare it with the mixin documentation. Move the main explanation to the mixin documentation, retain a brief functions-section reference, and document how default() applies after mixins are filtered for arity.

Written by the indexing model from the issue text.

Assessment

Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.