Generation is now done with uglify. Also handle more cases