moving js out (end as test)