separate js into its own file