@drewsonne/maya-dates / Exports / Comment
Represents a free form comment that can be attached to many structures.
• new Comment(content
)
Create a new comment.
Name | Type | Description |
---|---|---|
content |
string |
Initial comment text. |
• content: string
Raw text content.
▸ empty(): boolean
Determine whether the comment is empty.
boolean
▸ equals(otherComment
): boolean
Compare two comments by their text content.
Name | Type |
---|---|
otherComment |
Comment |
boolean
▸ merge(other
): Comment
Merge this comment with another, returning a new comment instance.
Name | Type |
---|---|
other |
Comment |
▸ toString(): string
Convert the comment to a plain string.
string