Search keyword highlighting with jQuery

Alireza Bashiri
1 min readApr 29, 2019

You can make your search results a bit fancier by using a little of bit of jQuery to highlight your search keyword or going with more feature-rich tools e.g. https://markjs.io/

As once the legend said (was a wonderful person)

(less dependencies are better)

So as we already had jQuery in our Ruby On Rails project I decided to not add more dependencies and I just go with jQuery only.

Short story but hope it’d come in handy!

--

--

Alireza Bashiri

∞ Travel | Coding | Lifestyle ⦿ Bangkok | ✧ #freelancer ▷ Got a project? ⭣ www.upwork.com/fl/al3rez