English
@mmd-toolkit/usecase-no-empty-description-block
Disallow an accDescr block that holds no description.
✅ The recommended configuration enables this rule.
💡 This rule is manually fixable by editor suggestions.
mermaid.js accepts a closed, empty accDescr {} block without an error. Written first, it changes nothing; after a description, it removes that description.
Rule Details
This rule applies to use case diagrams (usecase-beta). It reports a closed accDescr block holding nothing or only whitespace. A block holding only directives is also reported, although mermaid.js still applies their settings.
A block holding only comment lines is not reported by this rule. After a description, that block still clears it and is reported by usecase-no-duplicate-description.
Examples of incorrect code for this rule:
mmd
%% eslint @mmd-toolkit/usecase-no-empty-description-block: error
usecase-beta
A
accDescr {}Examples of correct code for this rule:
mmd
%% eslint @mmd-toolkit/usecase-no-empty-description-block: error
usecase-beta
accDescr {
Actors authenticate,
reset credentials, and sign out.
}Options
This rule has no options.
Related Rules
Version
This rule was introduced in @mmd-toolkit/eslint-plugin v0.1.0.