mermaid.source.keyword

mermaid.source

keyword(text) -> word, rest, spaced

Read the keyword a statement opens with

Returns the word of letters a statement opens with, the text after the word and its blanks, and true when a blank followed the word. A keyword is a whole word: a blank, :, { or the statement's end follows it. Returns nil for a statement that opens with none, so style1 and loopback->>A open with no keyword.