Cleaned code, added comments and removed unsused code. Added global configuration object with example to apocal-config.js.  Updated loader and apocal-js to use global object
Fixed conflict