Rearrange application.js and precompile assets for production