Have a look at this article. There is nothing Splunk specific going on here.
There are many tricks but all of them are easily circumvented or impractical to implement. You simply can't hide HTML or Javascript from being viewed by development tools in the browser.