Splitting out the js