Broke up function.js into sub-modules