wrapping all pieces into one and wrap with globals
initializing custom scopes, attaching lib to scopes, changing 'this' into parent within closure function