Revert "Revert "optimized js""

This reverts commit b6c8d985b8d7c149fe3b9be90c1aef3e96bd613c.