WIP: Optimize file.js and use it for everything