mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Add cacheDirectory support for babel-loader. (#487)
This will improve the initial babel compilation specially for larger projects.
This commit is contained in:
parent
f6ece560e4
commit
f7b9cb009f
|
@ -86,6 +86,7 @@ export default async function createCompiler (dir, { dev = false, quiet = false
|
|||
|
||||
let mainBabelOptions = {
|
||||
babelrc: false,
|
||||
cacheDirectory: true,
|
||||
sourceMaps: dev ? 'both' : false,
|
||||
presets: [
|
||||
require.resolve('./babel/preset')
|
||||
|
@ -127,6 +128,7 @@ export default async function createCompiler (dir, { dev = false, quiet = false
|
|||
include: nextPagesDir,
|
||||
query: {
|
||||
babelrc: false,
|
||||
cacheDirectory: true,
|
||||
sourceMaps: dev ? 'both' : false,
|
||||
plugins: [
|
||||
[
|
||||
|
|
Loading…
Reference in a new issue