for working example, see http://codepen.io/anon/pen/pyYJzv
If you have
<div>
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do. Eiusmod tempor incididunt ut labore et dolore magna aliqu.
Lorem IPSUM dolor sit amet, consectetur adipisicing elit, sed do. Eiusmod tempor incididunt ut labore et dolore magna aliqu.
</div>
and search for ipsum
$("div").blast({ delimiter: /ipsum/gi, debug:true });
notice the case of ipsum in both sentences. The result is
<div aria-label="..." class="blast-root">
Lorem<span class="blast" aria-hidden="true" style="background-color: rgb(7, 93, 154);"> ipsu</span>m dolor sit amet, consectetur adipisicing elit, sed do. Eiusmod tempor incididunt ut labore et dolore magna aliqu.
Lorem <span class="blast" aria-hidden="true" style="background-color: rgb(241, 33, 133);">IPSUM</span> dolor sit amet, consectetur adipisicing elit, sed do. Eiusmod tempor incididunt ut labore et dolore magna aliqu.
</div>
notice that the first instance is offset by 1
<span ...> ipsu</span>m
My workaround is to lower-case the comparison of matchText and subMatchText, although I don't think this is the correct solution as simple lowercase comparisons are not necessarily appropriate in all locales:
https://github.com/saviourofdp/blast/commit/1a171d62c3af3fa2e980cebe76e1cd9a39e7dbc8