Faizul Hasan
Faizul Hasan

Reputation: 623

Javascript source code finding

I have a external xxxx.js file where its contents are in non-understandable format.

Eg: {G(d&&!E.6c(d)){E.2A+=(E.2A?" ":"") etc.

I don't understand how this code has been done since I am new to this kind of development. Can anybody help me in finding this code??

Thanks...

Upvotes: 0

Views: 150

Answers (3)

Hemant Metalia
Hemant Metalia

Reputation: 30648

This kind of code are because of the js is in the min form. min form of a js means that it is converted to minimum code as much as possible by shortenning the name of the variables and trimming spaces, removing comments, etc...

There are a number of reasons why compressing your javascript files is a good idea:

  1. Quicker download times for your users.
  2. Reduced bandwidth consumption of your website.
  3. Reduced number of HTTP requests on your server when combining many javascript files into one compressed file, thus reducing the server load and allowing more visitors to access your website.
  4. Comments and whitespace are not needed for javascript execution; Removing them will speed up script execution times.

Upvotes: 0

Alnitak
Alnitak

Reputation: 339816

The code has been through a "minifier", designed to:

  1. make the code shorter
  2. obfuscate the code

Upvotes: 1

Quentin
Quentin

Reputation: 943560

Ask whomever provided you with the code for the development/debug version of it. The code you have has been optimised for size and isn't designed to be touched by hand.

Upvotes: 1

Related Questions