Split js into separate file