Add improved javascript