Removed unused comment
Deduplication of functions

The creation of the js/lib.js file to dump all duplicated code
that is shared between scripts. This allow us to be more
organized