Moved frontend module loader to a separate file