Issue #11. Unminified script version added for the debug
Issue #12. Code refactoring