I have spend whole day on profiling next.js compiling performance and one of the easy hacks to reduce built time is avoid doing full `stats.toJson()` that is heavy by default.
The prepares for next-server.
I also took this as an opportunity to get all build directory paths from a single location, as they were previously scattered across webpack/babel plugins and loaders.