I built system to index and search C#, SQL and JavaScript source files. It shows hits for the given search term on the home page with ability to see more details on each hit. Adding syntax highlight to the search fragments of the source files with Prism with the exception of one hiccup was very smooth and here's how it looks after searching for "and":

Clicking first hit produces this page:

However, here's where the wrinkle was. I wanted Prism to highlight syntax and also highlight the search terms. Hit highlights come from Lucene search engine library and wrapped up into <kbd> html tags - <kbd>AND</kbd>. It turned out that while Prism highlights the source it strips off html tags and all my search hits in kbd's were gone after the page was loaded.

Luckily I was pointed out to awesome Prism plugin which does just that - preserves certain html tags. I also wanted to thank author of this jsfiddle to illustrate the plugin usage. It is pretty much a matter of specifying which html tags should be kept and referencing the plugin source.