Move js to sep file