What are you trying to obfuscate code for?
It adds nothing to client confidence if they happen to review your web page code and someone with a bit more knowledge can decode your script.
If you are trying to "protect" your programming, you should know that the pinned thread at the head of this forum will explain a few things to you about code obfuscation and you should also know that while you as the originator of any code have automatic copyright, the internet is like the wild west, anything goes because no one organisation assists with copyright infringement other than having deep pockets and a rock solid case against the person(s) infringing on your copyright.
In plain English, unless you want to lose it, don't use it. Its that simple. Trying to hide it doesn't solve anything and in the long run bloats your web page code, you also have the issue of you breaking your site where visitors end up staring at a blank page because they either have JavaScript off or the browser (and they do exist) does not understand JavaScript.