Static Functions
12 Sep 20251 minute to read
Root static functions of Base Library
rtrim
Remove trailing ācās. Equivalent to str.replace(/c$/, āā).
/c$/ is vulnerable to REDOS.
| Parameter | Type | Description |
|---|---|---|
| str | string |
The string |
| c | string |
The character to trim |
| invert (optional) | boolean |
Remove suffix of non-c chars instead. Default falsey. |
Returns string
marked
Compiles markdown to HTML asynchronously.
| Parameter | Type | Description |
|---|---|---|
| src | string |
String of markdown source to be compiled |
| options |
MarkedOptions & Object
|
Hash of options, having async: true |
Returns Promise