Software Design/Cognitive load
In a more general sense used in the Software Design project, cognitive load is the effect of a developer expending more mental efforts while working on a codebase (and, by extension, on individual tasks), either because they need to
- Learn a lot of details
- Manipulate many intertwined objects or concepts in their minds (which requires disproportionally more mental energy than keeping in mind the same number of independent objects)
- Sustain their focus on the tasks at hand in the face of distractions imposed by the workflow (which may be in part determined by the code itself, e. g. see quality How much navigation is needed while working with code) or by the code itself, e. g. inconsistent style
As a high-level code, interface, or software quality, cognitive load may be defined as the expected amount of cognitive load which will be imposed on developers of the code or the users of the interface or the software during their work with the corresponding code, interface, or software.
Relations to qualities[edit | edit source]
Steepness of learning curve contributes to cognitive load: these qualities are both proxies of the amount of information that developers or readers need to learn in order to work with or just understand the code.
Relevant practices[edit | edit source]
- Link to a ticket from an unusual place in code
- Object access chains: both hiding and exposing them may reduce the cognitive load of working with the code, depending on the context.
See also[edit | edit source]
Other symptoms of complexity, according to A Philosophy of Software Design: