modify syntax of javascript