I'm building a CLI with Node.js and want to add less/more like pagination.
I can just stdout
the output and pipe it to less
like this
but I'm not able to add the text highlight just like git log
in the first picture.
I have searched about it but couldn't find any relevant info. Would really appreciate any help or references