Adding js scripts compression for more one position.

Adding js scripts compression for more one position. Now the script can compress the JS files divided by the position they are set and import them there.

This was actually done with the stylesheets so I guess you wanted to do it with the scripts as well. Anyway I needed to add this for my project and it works like charm so far.