Feature/amd

Fixed formatting and support of AMD (Asynchronous module definition).