You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My suggestion is to use a horizontal line to manually separate attributes and functions.
Reason
By default, this library separates attributes from methods using parentheses. However, in strongly typed programming languages, types can sometimes contain parentheses to make it explicit. For Mermaid, it thought it was a method, whereas it's actually an attribute.
Example
classDiagram
class Circle {
-@radius : Array(Int32)
----------------------------
#initialize(radius : Array(Int32))
+add_number(number : Int32) self
}
This example shows a class with an attribute and methods. A horizontal line (which is a sequence of - characters) is placed between the two. To ensure that a horizontal line works, at least 3 or 4 - characters must be used.
Screenshots
No response
The text was updated successfully, but these errors were encountered:
Proposal
My suggestion is to use a horizontal line to manually separate attributes and functions.
Reason
By default, this library separates attributes from methods using parentheses. However, in strongly typed programming languages, types can sometimes contain parentheses to make it explicit. For Mermaid, it thought it was a method, whereas it's actually an attribute.
Example
This example shows a class with an attribute and methods. A horizontal line (which is a sequence of
-
characters) is placed between the two. To ensure that a horizontal line works, at least 3 or 4-
characters must be used.Screenshots
No response
The text was updated successfully, but these errors were encountered: