Edgewise API
Docs
GitHub
Preparing search index...
helpers
replaceSpans
Function replaceSpans
replaceSpans
(
text
:
string
,
found
:
Pick
<
Span
,
"type"
|
"start"
|
"end"
>
[]
,
mask
:
(
s
:
Pick
<
Span
,
"start"
|
"end"
|
"type"
>
)
=>
string
,
)
:
string
Replace spans in text. Spans must not overlap; they are applied right to left.
Parameters
text
:
string
found
:
Pick
<
Span
,
"type"
|
"start"
|
"end"
>
[]
mask
:
(
s
:
Pick
<
Span
,
"start"
|
"end"
|
"type"
>
)
=>
string
Returns
string
Settings
Member Visibility
Protected
Inherited
Theme
OS
Light
Dark
Docs
GitHub
Edgewise API
Loading...
Replace spans in text. Spans must not overlap; they are applied right to left.