moved javascripts to separated js files