-1

Many websites, like Catch.com, depend on JavaScript heavily. Catch.com for example, when save the webpage, a javascript file: catchapp.js is downloaded, but it's content begins with strange codes, like:

function e(a) { throw a; } 
var i = void 0, j = !0, k = null, m = !1; 
function ba() { return function (a) { return a } } 
function ca() { return function () { } } 
function da(a) { return function (b) { this[a] = b } } 

So do they use some tools to change their js files before release?

Paul Sweatte
  • 24,148
  • 7
  • 127
  • 265
Brent Jiang
  • 377
  • 1
  • 2
  • 11

1 Answers1

1

They use JavaScript minification tools like jscompress. This will reduce the filesize, speed up the user's download and reduce bandwidth costs. It also works as code obfuscation.

Zeta
  • 103,620
  • 13
  • 194
  • 236
  • Yeah, it is a minifier. I have looked at a few, but what would be really cool is if we could find one that integrates with the build process on an IDE such as Netbeans and Visual Studio. I have yet to find one that does this. – Zoidberg Feb 27 '12 at 13:18