Skip to content

Commit 0cc1ed0

Browse files
committed
make react external on webpack
1 parent 9b06a22 commit 0cc1ed0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

server/build.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,10 @@ export function bundle (path, { root = process.cwd() } = {}) {
5555
'next/head',
5656
'next/link',
5757
'next/component',
58-
'next/app'
58+
'next/app',
59+
{
60+
[require.resolve('react')]: 'react'
61+
}
5962
],
6063
resolveLoader: {
6164
root: resolve(__dirname, '..', '..', 'node_modules')

0 commit comments

Comments
 (0)