Move the js functions (print) to their own file.