Extracted js/css building into cog.js