javascript manager and reorganization