* Remove babell-plugin-transform-react-constant-elements.
With this, our shared-modules example's counter won't work in
production mode. (as this plugin enabled)
So, we could see more issues like this.
That's why we don't need this at this time.
* Update package.json.
* Add babel-preset-2016 support.
This adds the support for Exponentiation operator (**)
* Use babel-preset-latest.
* Remove babel-plugin-transform-async-to-generator in favor of babel-plugin-latest
It has es2017 preset and it comes with the above plugin.
* Find custom babel config location properly.
Earlier we simply check for the .bablerc file in the dir.
But the actual logic is much complex.
Now we are using the babel's actual logic to find the
custom config location.
* Fix failing tests.
* Let webpack2 to handle ES2015 module system
Since Node.js can't do that, we need to transpile
ES2015 module system in the emit-file-loader.
* Use sourceMaps only in dev.
* Introduce a transform option to emit-file-loader
So, we can move our ES2015 transpile code with that option.
* Remove unwanted argument options.
* Update comments.
* Use dev flag instead of NODE_ENV
* Remove default next pages compilation from the main babel-loader.
This will fix the issue when the user ignore node_modules
via our .babelrc option.
* Change babel-loaders 'query' to 'options'.
That's what's supported/recommended in webpack 2
* compile _document using webpack
* don't emit the bundle file of _document.js
* exclude _document.js from minChunks of CommonsChunkPlugin
* handle creation/removal of pages/_document.js
* improve path handlings
* Create a babel-preset for plugins and presets we use.
Anyone could get it via 'next/babel'
* Remove 'use strict' from the source.
* Add next/router to alias resolver in our babel preset.