Closed ztanner closed 5 years ago
Next.js 8.0.4 came with a change to add babel-plugin-dynamic-import-node to Next.js: https://github.com/zeit/next.js/pull/6811
This means that using jest-next-dynamic requires no custom babel configurations. One caveat is that the plugin will only be added when in a test environment, so added a note about making sure NODE_ENV is set to test.
jest-next-dynamic
Related: https://github.com/FormidableLabs/jest-next-dynamic/issues/6
cc @exogen
This behavior has changed again in Next@9 making the plugin required, so going to close this.
Next.js 8.0.4 came with a change to add babel-plugin-dynamic-import-node to Next.js: https://github.com/zeit/next.js/pull/6811
This means that using
jest-next-dynamic
requires no custom babel configurations. One caveat is that the plugin will only be added when in a test environment, so added a note about making sure NODE_ENV is set to test.Related: https://github.com/FormidableLabs/jest-next-dynamic/issues/6
cc @exogen