update javascripts implementation in view logic