{"_id":"next-transpile-modules","_rev":"60-69a922a39a1ee8f919b34f7d081db9eb","name":"next-transpile-modules","dist-tags":{"latest":"10.0.1","old":"1.3.0","beta":"5.0.0-beta.14"},"versions":{"2.0.0":{"name":"next-transpile-modules","version":"2.0.0","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"echo \"Error: no test specified\" && exit 1","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"eslint":"5.12.1","eslint-config-semistandard":"^13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0"},"gitHead":"1414067dec304a0095cfd4b8b080695abbc4e5bd","_id":"next-transpile-modules@2.0.0","_npmVersion":"6.4.1","_nodeVersion":"10.15.0","_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"dist":{"integrity":"sha512-W+jV3Kg+bLmGbntYfrGBloiV+ABOXt+GMI2aIUcM29yaPVDsIn2vWoyH6PA2ZXXgILm7xmyPfi30/0idbAmsaA==","shasum":"ecbac0a5ad97ec7c0f47326bcdb64b6e11cf445c","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-2.0.0.tgz","fileCount":4,"unpackedSize":7124,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcYtojCRA9TVsSAnZWagAAGlQP/05HZvenndKf+Z0CYDv6\nW/Upl+XJMjvitq4hus5OCZcGTx7/fElFTzLjwJyo0Y5NhEM4eNAVJfhx51Z6\nC1uq4zY/FuhWCuTPRMKKMRZ/gLjeaRgCbXVpuuCQUDtlGxNx2ZN6as+XaBzH\nBD3dwYxs9FdEV08o6fbodDMic5aIC1C6Yp1OCjTUZRD0MqoBYEop8l3u0RWx\nwA2Ezji+I+uIJw2yJrGEnLBhwM66J3wCrAhGx0z4ASD6AokYT7VnNLSMBV4z\nWK6Y2RXcwWwHppvJWUSjAoGXyAgBZfPSWEAZXNlHfkx6edw5I9y/c/p6mZhb\nmwEDjg7Yw/7h1pxoNWLW6BzZt4EA4RIpivEBNVXNykY3mnEKo3Wa++r4BSPR\ntY/qJB0MomgqbC/P4ydrPTvvdDiTnwSX+O72ndpmP8KP9UVx+6h2XF/ngThf\nG7vzYKUTjHLr27H6g7W078AJwjLAswviV1aUdOhxkmJlItfXMU/tPqP4Tvly\nRGVC/Um62fC9PE22EB1yj+91vbMsVm5Ty4kVS6JXmywccbbb3IK726b+mV7/\notbcRHmO3v1HgZo8GTZGClJ2KKPyoV+ekZ99W94tmuF2kG6qwK0/7q7FG+4Z\nnYZv4o9MoMTqwV06L/DcvH0l8lTDxBYQ02L/RxFcnNp6quu9LgsKZVcBfJue\nRzP0\r\n=6sC5\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCJK4MiW5AoiDz09qjNoOVMDFmA6TATJUTCKak3gfw8UwIgWX8nl3u1IbWuu1taIHWiOMbA/jdbI9nx43dc8pvnbsE="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_2.0.0_1549982243060_0.04800607607257423"},"_hasShrinkwrap":false},"1.1.0":{"name":"next-transpile-modules","version":"1.1.0","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"echo \"Error: no test specified\" && exit 1","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"eslint":"5.12.1","eslint-config-semistandard":"^13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0"},"readme":"# Next.js + Transpile `node_modules`\n\nTranspile untranspiled modules from `node_modules`.\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n## Compatibility table\n\n| Next.js version | Plugin version |\n|-----------------|----------------|\n| Next.js 8       | 2.x            |\n| Next.js 6 / 7   | 1.x            |\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\nClassic:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules');\n\nmodule.exports = withTM({\n  transpileModules: ['somemodule', 'and-another']\n});\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\nWith `next-typescript`:\n\n```js\nconst withTypescript = require('@zeit/next-typescript');\nconst withTM = require('next-transpile-modules');\n\nmodule.exports = withTypescript(\n  withTM({\n    transpileModules: ['somemodule', 'and-another']\n  })\n);\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `.babelrc`/`babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and do not intend to help local development with local modules**.\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n","readmeFilename":"README.md","gitHead":"496cc7946062656fff0c61dfb33c6a5b7b1fe669","_id":"next-transpile-modules@1.1.0","_npmVersion":"6.4.1","_nodeVersion":"10.15.0","_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"dist":{"integrity":"sha512-M4keE0Xk/2nTd2BMneGALp2SZGVMG/gSSxxFLZKYg8E5RcojtALm7YUWbeb929+YW5OSVKB9T+FUmw9iXAXRog==","shasum":"9b5bd958b689df30fe267e98200dcd4b60425d77","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-1.1.0.tgz","fileCount":4,"unpackedSize":7124,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcYt0ECRA9TVsSAnZWagAAdbsP/3QoSuyqj7YiGnRBq5/F\n9x9ps+4EO54gXna/uyaziLIptgw/6XW/ABAu9EdWxIrOzYzNyAAPM5ugA5Ui\nuULTn0VZXjGapH33hJVDYHT9wiubqdCt5yuPEeEeqm+G967v5K+WH2mKsOEu\nOTiCjV1ox/J/E+7rQmZGSg1cNu+d+dCx07PgYp+qdxw4n5VBtoXwR4mt4SLc\nWvLbHy27vq09CjaeSBS8UIv4LiJVItT0qyyvMIFMj8RQQ6Z1B3aDLRTXGF2F\nu5f2wEmwbInl9Ksc1WxLHPlkf9XqImFAOeQh27UvSigOsliSA2umGYr/SuiM\nqLTvL1wWxadKKVPz362Smm3jUlZuBFp9k0OtFf5zCe7ix3kDYa+PJGEieb7N\nbU9dBw/agBtoz+4nw+xviB+EcEk4EpmnwPBQ6F8WTUGGJopAHhqlihCu73Oc\nUCoVGAyy6THS0iYHXqhbxqien6/goD9C88hSY7HDUD168EkdlV/pgGCT5FCE\nRs55I1gXBFG/ghsNGeAkAMmk07bD6jk2G8uzI0kCtGDOtFAZ2pYaKSPUcFah\ny9Hdl1hDuCvM6X+PnobkzRRVxw4VjtZd7sYs2gBLjQ/tNi3GQXBTs0eKqpsA\nuF71zUgacPRwug5ZcqNRhRLKTNg3xONCC4hJKWWx6H26/gthGAANyy4rQo8Z\n9UzC\r\n=jblV\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCz5Dy35wq/jC7xPIIdN/RbI+92QefQzC6dodNiWmHjhQIgOWvzQMVEUhQh51TA8Q2YPmy00NvNdLeqfx32eOqE5B0="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_1.1.0_1549982979370_0.4076917855624549"},"_hasShrinkwrap":false},"2.1.0":{"name":"next-transpile-modules","version":"2.1.0","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"echo \"Error: no test specified\" && exit 1","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"eslint":"5.12.1","eslint-config-semistandard":"^13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0"},"gitHead":"7bf53d7dccfa99674f9687e840573ea6d344d40f","_id":"next-transpile-modules@2.1.0","_nodeVersion":"10.15.0","_npmVersion":"6.8.0","dist":{"integrity":"sha512-qHGjnTGyfW5JJ9q0xh3YBNuBNHuxd0cgXgrDRBnw+d913K4Nw93xj74t9lwAIMovWgeCHqBgFvg1lMkzr0/zjg==","shasum":"e12891e273803fb9488b5ba54df5a8905b56b25a","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-2.1.0.tgz","fileCount":4,"unpackedSize":8502,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJceZDQCRA9TVsSAnZWagAAOtoP/RPQ7W7ccLK4Uu5Eo5zX\nNZ8c91FzplCTKQANMlhh2Cl2Foa/n8c3bsV+apZXN6pYKil6ZO+I3BnRzYYb\n5lxRsslO597aHavaMCM1Pv0jE/MsmEsMZ0/U8my77K7FfDBoG5bqBh/cB80H\neL9Uhb8k+MM3UCJFeuK8dlSisKlnHHiNYuZQdD68SAlhSdGX5KW+YwJHyuZ7\n1TKvxBt0AsHdwB3RpsU2sVkWT4JJYAOsuToeB81OYd2Kw/a5OHJY0kk2Q1DJ\n75/ClwozR/6/DZEZij6uK92dPBZp1yEbmqL9hYMPqTdOb3ovS/+pxzQGGkQu\n2sqyQ9PcqHX0ih2E/SDo655Lk1TVgqnSbqHHY7x2G0RwcoIiBt9KOgAFkWoh\n8/ZY9U06gmxOJMDTaaNsuy2RcQIz2wPFZfozCUiKrZAnL+ksEeaM3JS+gdxv\nNb4nXh9tuJM86LZc2CDAuk4uRzFDkx+YnTC8cfFXR2CbbzRgssMHyC0wUKt8\nRaitJGdzQbXrnHy1n6A6cwPFmpGTwB6hO6wB8EICkFm7O7aPwSin5Gg2jMVO\nz8KtxV8hXAe9x/rd3NygN9HfHM9fBo7i03E52ZumxMEvWPnzgUuCeIiTbvDE\n5vrdcsRJBWTudKwnZO6khJdOM/ETtNe38i3VAs6WbIfCGx4sGa8cJq9+s8IR\n4WQi\r\n=teWN\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHtOPQfws8WddMWiUUqR8sdFcYoVxoa3szR7yMEEoPxvAiAL558cpxbp+gY92pT3OGuLK4YatquXDNUIzSxbJbQxVQ=="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_2.1.0_1551470800067_0.5413416335774803"},"_hasShrinkwrap":false},"1.2.0":{"name":"next-transpile-modules","version":"1.2.0","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"echo \"Error: no test specified\" && exit 1","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"eslint":"5.12.1","eslint-config-semistandard":"^13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0"},"readme":"# Next.js + Transpile `node_modules`\n\nTranspile untranspiled modules from `node_modules`.\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n## Compatibility table\n\n| Next.js version | Plugin version |\n|-----------------|----------------|\n| Next.js 8       | 2.x            |\n| Next.js 6 / 7   | 1.x            |\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\nClassic:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules');\n\nmodule.exports = withTM({\n  transpileModules: ['somemodule', 'and-another']\n});\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\nWith `next-typescript`:\n\n```js\nconst withTypescript = require('@zeit/next-typescript');\nconst withTM = require('next-transpile-modules');\n\nmodule.exports = withTypescript(\n  withTM({\n    transpileModules: ['somemodule', 'and-another']\n  })\n);\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `.babelrc`/`babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and do not intend to help local development with local modules**.\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n","readmeFilename":"README.md","gitHead":"6360744a042668cfa59dbd451d706b8621468dc8","_id":"next-transpile-modules@1.2.0","_nodeVersion":"10.15.0","_npmVersion":"6.8.0","dist":{"integrity":"sha512-eUWKDcHy/zM4URL3BAu1kGXNjqAtVjbCbyFPTMgllFfBDpUp79FGMaq3F2naTuAs1IKlpfzyfEdPtVqfEpqcqg==","shasum":"2925d2d34009a5461f9d7e05438ed6ae95c0703b","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-1.2.0.tgz","fileCount":4,"unpackedSize":7257,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJceZJjCRA9TVsSAnZWagAAQlcQAInYJ1zv0d75xuHw8zI9\n9M1ZpjtMBxOW/QBD6TJd29rij1ICGVDjl3bdiIhePsL0qVhY2VdIJ11nMSIJ\n4034iLVQG5NFMyIBthk2VYVXV0wwTejkLBc1yA+No1F1thXKCkMI2jV/8+0x\n+kUSamztE6IAXAZLVqQNqzpFkEKriy1ZzUYbRnJPZFZhOFJWlwJ5WeAl4Dib\nc9XKRVHh3Vo3uRErx6H6a0aKcKeEDKKWscv6cQzJGGcbx4xfBN+/QvkDM/Tf\nXd3oPkgch3Tdh2i4M2ppuf3xFV99o1q9GP8iEu/q8MVBq/0zsKFFgyDQAmE8\nIgWh0rtrypt3B0ihvK3bDrADkdmdtinT+bjIxQ5rL3AB/Eavy/0nxmnY3xKC\nRFUlES+WhvqXwN4x6KLSfN8gs5q4Q5ccAbtbNRDB3OdUzegZOrfFyhgvtCgn\n7Fy1SvyVteyu+HPwBcb0x16BwC3XVtrkaG7XUNDSaXRGtEFEwrY3Ran731aq\njxY+76ZH+iGGzzO9c3+qEBp9zKLjMKcbAAYuNdknbSl9tP+yy7yVSI3f5v8Q\n99tMIUfpUzllVNDgI3lDprz4AfQHkZRqW1/RKVZgrkm0Fwmc4a7y/8Ea0TZf\n+yWQ6zErN3R1zt2p5jjyFsjvJ5FTkubTocDKSeF9WrGG6u16PrMNDLd0wezH\npneH\r\n=6Ngk\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGuIMvQQYI27rlNOxclxtAfw8JdtPJ6L2/wrwpHQoGpuAiEA2E3+gzHiOSgJu/IpQv3gjQmSEmfacUwmS+Fdhcm9dfE="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_1.2.0_1551471202602_0.7888130469351156"},"_hasShrinkwrap":false},"1.3.0":{"name":"next-transpile-modules","version":"1.3.0","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"anymatch":"2.0.0","eslint":"5.12.1","eslint-config-semistandard":"13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-jest":"22.3.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0","jest":"24.1.0","npm":"6.8.0","rewire":"4.0.1"},"readme":"# Next.js + Transpile `node_modules`\n\nTranspile untranspiled modules from `node_modules`.\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n## Compatibility table\n\n| Next.js version | Plugin version |\n|-----------------|----------------|\n| Next.js 8       | 2.x            |\n| Next.js 6 / 7   | 1.x            |\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\nClassic:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules');\n\nmodule.exports = withTM({\n  transpileModules: ['somemodule', 'and-another']\n});\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\nWith `next-typescript`:\n\n```js\nconst withTypescript = require('@zeit/next-typescript');\nconst withTM = require('next-transpile-modules');\n\nmodule.exports = withTypescript(\n  withTM({\n    transpileModules: ['somemodule', 'and-another']\n  })\n);\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is a project-wide Babel configuration, when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and do not intend to help local development with local modules**.\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n","readmeFilename":"README.md","gitHead":"94c9f778b3c21553201ae387363dbc2a11a95f38","_id":"next-transpile-modules@1.3.0","_nodeVersion":"10.15.0","_npmVersion":"6.8.0","dist":{"integrity":"sha512-LGX4GUOiVijrLNCWzBhK9gLsGOcGDkkpQS1DDS6tlbXV4xCeb6bFrCBFW3AlDlh5yzhWFNf+RV7QnruwocO0Mw==","shasum":"b524c395cd2dc50982fae19da1180a5d7a492cc1","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-1.3.0.tgz","fileCount":4,"unpackedSize":8187,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcftGRCRA9TVsSAnZWagAA/kAP/0z2imMJSKOHwvsXMGz5\nLXuKxvuF2es+vfHjXfKp+YokYCqcUbAUJwrxZgXI3n6UD3XHq5NH9bCr3wVS\nMzKy5QRsuuskfyqxo9VuiNRC8rErOG4XDCkcgHZOOIMDtyuitFsI2R7Z89BF\nsmuozkme/FcV1IneeUP7sjzJEm0d0Wkgoe6MEhvMpShQYmtAJqx7RJ2Adm2b\nLm8WvYiBVNAfzfsl5Az+skwwjl5aiokcY3K6/rwCmslIxz1NNobNEytNMQQ0\no0ug8OhEBN2y+BG6LVzJHcejBvLXGShn2nPSeV63wV/S7emlTcc9IZnnEKl9\nRbr/JcBG0TXeRyDTaK4Prg8kbUlUajTtO8ryy37ktbLdgXYOFBDaIGiGe2yY\n1gaYm5qnTX329CnRGQ/0BYhQdW18nBJRQylGIrMdTjOyG1sJoA3/0mb8asXd\n4u1kUrL9tX/et2hM6wwDwwCGXfAWBrqpX3XkqUTmRLAXls5zTF1o62Oa+Uu8\nZH4Xg1BFhXhMl+PJMh5YmQyHpG19v/iKS3jwutZFaWgbVSf+Yis1Oo289+sg\nm4l4hQQawaBKtOW9YGTU+Yb4D4yb/GKif9+6LX3XjuA9Vk23ctdhaY0vkh2i\nsgnm3DwpPRZ+OhkifwUiXAbyrCMTnfUqvkGZH06WWlAopCpVI2q+A5pDOWza\nk+fv\r\n=6XFO\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDajKHJcF/GVrLP4JGbarfAg4R0s3iWcrQ0h6jLyi+DoAiEA/81yci5wryobtsKM+EtJ89QmujLyH/sQmtltvMCQkZU="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_1.3.0_1551815056432_0.583275387107143"},"_hasShrinkwrap":false},"2.2.0":{"name":"next-transpile-modules","version":"2.2.0","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"anymatch":"2.0.0","eslint":"5.12.1","eslint-config-semistandard":"13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-jest":"22.3.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0","jest":"24.1.0","npm":"6.8.0","rewire":"4.0.1"},"gitHead":"34c7a7772f729f324c9857bd68f301397582933a","_id":"next-transpile-modules@2.2.0","_nodeVersion":"10.15.0","_npmVersion":"6.8.0","dist":{"integrity":"sha512-AY2Rw5lYjWJgpTTA+cfhakTcaG32PpMqpCjqA0DsfHZXXPPIPUjONVXEHcliENKo3H7mdlDgJM8Imy4+Hz96Tw==","shasum":"1cd4b8b3e8bc22107c31ba38cbc889bc483bbae9","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-2.2.0.tgz","fileCount":4,"unpackedSize":9432,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcftKJCRA9TVsSAnZWagAA+PYP+gPoqU6wJvzf5OJOibp+\nCeVoebYCxE2tB2JvxrSv9fXdy7Fw+aigpBLPBRUOt+AM0sGx7BfJ5Z0ykjjx\nT+tyA8EMCCE+8uresfCl+cO5wVnRrFHmHXIXXpwhUYVco1hkiH933xgPLHWU\nP0bC5zCZ4J8+I8f3Zwj9GQl45J72E1q91gzLT/qKGfXQy9ojpSKCypulL6HK\n6ywleszHdRGZOVQEcogAa+ZyJipjVE+XQ/hvrqKKDOLEWWgzyGRq0d0nQp27\n12SdZkjh4zkJiD0m31qDwbLB4Iwa6jFB1Yr4ihH7PqhkZeMt6zgggdIoRHqt\nOQq6stVxV02rBRFb1U/6jqRxCekrG0/criXtsFZuHknWTLr3uAXYW/6NQBWK\nLqXwozcb3zf6zlFkKoH1hZZXT8ogemF544Capjt4VQ2yr/9so9rC7p1NLcTb\nJJfp/TCMWtt/yjz/7VbJxW2ZjGbzIJOb9LizZBqzUFCBTBGA98Ih+WaULMT3\nCzB5cQ5KV7305gee2odYmi4So9oaW3SRhwy7rnh6NWm1RhssU2UG/PIhRTth\nqagklT3gVUaVvK1Bg4VQJenKbB0aSQ1ePiFFFqcda2YbU5GiX2WkCiw/54q5\n1EEDWNzoUObUS7HpmOf6RQuhZZVcftMB5Ho6lPHAM9KRkJHSufw/vwSDAgWe\njDlh\r\n=9bDK\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEjML8LRWWyR4ao7b6ozJja6l3mY2Mio3JVld0wnXSruAiEA9M8X4qpW5BZPjrcdX5jBtqaxPBuxKUz7QIJ6ms+reFs="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_2.2.0_1551815305240_0.6054023483988609"},"_hasShrinkwrap":false},"2.3.0":{"name":"next-transpile-modules","version":"2.3.0","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"anymatch":"2.0.0","eslint":"5.12.1","eslint-config-semistandard":"13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-jest":"22.3.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0","jest":"24.1.0","npm":"6.8.0","rewire":"4.0.1"},"gitHead":"db2a9da1c8c4fedec1dd2d6079b575ae28b71a7d","_id":"next-transpile-modules@2.3.0","_nodeVersion":"10.15.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-qY9HSLMfxfZ44vdbHlq6xHH7UElfA4fXD18zjpgSqX8XPsWpZogeNRKqEPYVrq5Jlz3M6TrzDW4v7ps61s9pMw==","shasum":"ec510aed70588ade69debe4eea94cdc5fc5145a3","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-2.3.0.tgz","fileCount":4,"unpackedSize":9833,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJctuA0CRA9TVsSAnZWagAAUhoQAJOALcuRuBeC7fZCz0IH\nHFOs9NA0yE0vRZbVQwXnpswc57BzvcduDpCmnQvrhLUwwV4P3AOiu48p1Y6F\nGfEaP54A2H8o8QV2uMMcuDlMnzL30GYhakJEtkXT3rlxX0FcsI4ljYxV4heF\nfVR6K+zwXMs/QrM+u+Haf4ENQosQMmpl0/9LuDe/oevprhi7ZPBBmc5WQCt0\nr91RlIqrZ0W6VKnG1XiQCcfZEsiMchOKYUZN/DuCxtVBqGTW+yV2Qd2lGznV\no+tsX7JXrJy7/SInySaAcbxbvUpiBLkZgij6hi+uU1p/WHbZeTCz03DeoTXT\nUSS4sbYE7LuXZ41pJbpLiKpRrz4hAuURKUy6PxS6ZCeIeL80Qcydj0XWnJMO\nFeQ8f8TMQZcFoFwMhzmptfZv4J9ealfWeUaV0jFGthQw03kK+HNOXvHEpQfB\nx6+Cwt8kE0aJRNq7fim9mOJYFYLN16YIXgFcuSQPuaLM+eii+pe4XjGzysNe\nIjmIVioDfHPA9t4m/Wepy1IBT2I7lQsRl57TvM8QHYFWPHFtYwYdsKO+lBPV\nODfvPRHI6Y4QavLOtZD6ed19Y4a4idEJ/hDMYfwOEA4dD7sLraPwyka6Zl78\nlry70dyp4dOOAYYXN20ideczTNFhEyvCw1pDN32JutcKDReGVgkarL5L8pte\nNVRx\r\n=xCc4\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIE1rU08d6XJJ5E9OaihNLGdKlNVHI2wOg3Brz0PRGUvDAiAkBoLUM+u+6/l0Zyc1bQvJasRG6KgAGYQq03oqEeSVmA=="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_2.3.0_1555488819184_0.3205149581522093"},"_hasShrinkwrap":false},"2.3.1":{"name":"next-transpile-modules","version":"2.3.1","main":"index.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","lint":"eslint ."},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel"],"dependencies":{},"devDependencies":{"anymatch":"2.0.0","eslint":"5.12.1","eslint-config-semistandard":"13.0.0","eslint-config-standard":"12.0.0","eslint-plugin-import":"2.15.0","eslint-plugin-jest":"22.3.0","eslint-plugin-node":"8.0.1","eslint-plugin-promise":"4.0.1","eslint-plugin-standard":"4.0.0","jest":"24.1.0","npm":"6.8.0","rewire":"4.0.1"},"gitHead":"a63322b0f5c78c9f6b7a14ec3a46d304b125755b","_id":"next-transpile-modules@2.3.1","_nodeVersion":"10.15.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-euNOBAk/CXZA6binwL47+QpcxAmK1pzH2zjF7XnRN55f2iuN/ecpUw5p3x4bikFu0yDPtSLS92nv9fcgcCo0vg==","shasum":"8977c070912fbc3e927c662431fc4e91ae335b43","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-2.3.1.tgz","fileCount":4,"unpackedSize":9792,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJctuvzCRA9TVsSAnZWagAAxaYP/AhgznBvyyhq+3IeRKeo\n1CM9Kzi07aV+PBPfGbfU28um5pDA9SlLtbNYWgQ+ttJ27FIGPeSl41hqo89D\nziKS8Hr+DOO17ZxixnHy25FpF727TFCPklvXNyIbnoROsR6ijDrpQhYn4+30\n0h5Qt+foWiucIBS5aBM08Rc8YqXJY462J3iMTi/kt7AeF04NmvkmX+iq6ain\n5Tvm1yCL0s+L7kgp/kI++QZn4zD4Pq2AwmcDGkUrGx4pDCLe3/tFWSaEiHme\ni5GO83IYVA+rLD8hkBAqoq6frYcPbUZfGXexAKy8U9MzdO2ipWdZhByhXmT4\nRSinmjFdC0F01e5AaGdAiHr8pfm55CwdpgjDLjJtbFBeKtsskJllpQoqvxLr\n6NxTHzrW6q22oQ4gcLsLEIm5u+oOy4lTkgPITxTjJmFtujFY9lkzKOZwgOgO\n0F6t4H58NRiloeNVdMgr7kO5PGfrvZjXfkpgtsU4rcN4ZX/fH/zwQJIKUGFr\noTCFDbf/ie3fPyC9dywL8Q3PcVciFfiQZe+ts+T36NHX0NC4y63+yvBWbOGI\nFpR1EWM1KIETqNVtJnBo1irmy+cJjFSvDSda60qkxd21iMujkZ0VjtIV2if2\n34VtI0JznD7fFAIZCeALZE77AP1QuAUD4dU7DyXUBOLMeEIsU5HVhRVkPvqG\ne95j\r\n=GTgC\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC8ikvZfZ/nod8erM8IUqNYPHnSf9VdVKMnxEesFNifrwIhALFSsMlpMrq8AKLyMrX9RL7ISwvaqqQVqed/G7BdmTVZ"}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_2.3.1_1555491826640_0.04030754726955643"},"_hasShrinkwrap":false},"3.0.0":{"name":"next-transpile-modules","version":"3.0.0","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\""},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"^4.3.1","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.9.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.0","eslint-plugin-jest":"23.6.0","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"24.9.0","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"^2.0.0","rewire":"4.0.1"},"gitHead":"ccbf97717ca75eb64bd9df18bda272dae4a1ee4a","_id":"next-transpile-modules@3.0.0","_nodeVersion":"13.5.0","_npmVersion":"6.13.4","dist":{"integrity":"sha512-NwNYdQR02g0BrDTwr1o6aT/4DDacYC4bblEMfN8MkSs+HZjp9OOQFrgBq0kjL2X1uX4NxBOhOz46XLY1HGmd7g==","shasum":"c7f193b47534cec1761a1ad003c8e17abedbffc7","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-3.0.0.tgz","fileCount":4,"unpackedSize":13516,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeJaDwCRA9TVsSAnZWagAA7vMP/04M3gQxLMselZ74YdEZ\ngzd/vYk4Y5z9RiQFh/6UsDBVyMWU8xrIFunmE2/AYdxvXXQ2AWPCFqZUxTSc\n0jiLuaCwDVv6pDn1lLmANWZLHCZD1bDdPEZtjsJ24hBJLJNThyZaSYCgMZxF\njtCHkGZC+XryI8+7yrnVZ1UnA1WCSYF9t7GxF/AocFktWJ3BMxTDTcOKszDB\nyzpKD22vYwZZsOtFirycmYC7pNWS+Rs0qf4zGoBFAqrs8re9Sfzvbh7c3aF3\nUALQnjS2FXWMaPeJiJRrEDhbf+SZoOpWFn1HsciL7oDOjHyfGY4V9njkILrz\n3mbw2a9kQT2TpoHCrgsR7+mxLmh+kRFoU24EBN4WdNd7QQSaKfCNyJdY5wUO\n6NPRzUhTimNyjQtUQjM63xwCZAt3tAytCkREPxOHOwFQHa/iP/MWRVvwVY9h\nLprCLiWW6sLIKXHXfGlgi+bRARdz0RpcejZe5DBG1jwuyqevxhp0GxPV6re7\nqn62DMYDP08q40drpBbjidy9w9wkRkCPZb5IG8fddVLuZASoh+1d/LvKyeMG\ndEgs0tUtYA1O+uGJzyfVYwSqjkODCJd5xTiOO2R4GYTky1san1vshPK1Pd23\n6GUPh0/1soMDnUumkb+rpe4eLInt2DVikb4ExkkGhnsRikDnhdocrHK20FqZ\ncV4P\r\n=mNcV\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDIt5YVbQHCP+s4S+qqAmlm/8BFLNA0xiL+EgMtfHwy2QIhAOM4f5ONd5yiGSnTa+1CeWGDrRJNOj3hQTAnIqkA9HVZ"}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_3.0.0_1579524336450_0.695048788527407"},"_hasShrinkwrap":false},"3.0.1":{"name":"next-transpile-modules","version":"3.0.1","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\""},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"^4.3.1","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.9.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.0","eslint-plugin-jest":"23.6.0","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"24.9.0","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"^2.0.0","rewire":"4.0.1"},"gitHead":"1eeea157da3c774cdd090934652bf25fb52bebbc","_id":"next-transpile-modules@3.0.1","_nodeVersion":"13.6.0","_npmVersion":"6.13.4","dist":{"integrity":"sha512-DrqjpBlUPXLInZ6yuzz/9d/tprZHYGLyg9/Ppm2yBk5TdgPPFfvxVlNnopvjF/BqqLZBfuovfIlA6BWXPbQXww==","shasum":"8acfca125498deda73ee0d02b36c2699abc5952a","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-3.0.1.tgz","fileCount":4,"unpackedSize":13352,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeJ2d0CRA9TVsSAnZWagAApYwQAIIAx7VKIMa9I+wET67x\n5cZMhPhPcwvtl6H1wHMerDuIvooN0F3W8lkeyi2uOmuAV84L+PDax6aKrcIn\nA4dIs8o5N8SRAEZa55XuEA4QYr8FIWAjwkldtEnUawTNA7NT4eT090hkIHX+\nxpEddm2Of7Tf5iba9malS+UPHXtNhMANKVcRp8y5F2nX9ig3txZ49R35eXP6\n3Fwp4YcFakxHxGazBdQpydPYoOvAYnsgGdaX1SUSo/7VA1fik+MX7b58F8wW\nSGEpNzF7CCGdOzUpCZt/fmiBQkwkd2EtY/gloACsBrPo3xQOT5zHXPVqnlIv\n6a+ZSMdva2+VeldFPGIz2/p1RwituBk+B5HdaJ3cuQ7+Y8tY6IK9cVI4q3Qf\nIF7RWT947bHnkGMkZ+2utIXO0yETp8IIYoA50uYp7q6MtgAMq25svUaslkqb\n9VIQ9xd+lUizmdCZnFMv+jsC6f3myF1bONsbkLNqQlRcCI03gqs9Yal5ad17\nV4gGcMfJoN5AA5bQrJgXL3GMhyDaNp3k5kCXH/qok6V8PEffqM37vROIBlhE\n3RBF2kKXItiNI9XqUS4sHtjvZLLrbs/qD1iSihmoxZmARNwF/uMc0Co2ltZy\n6tQSAxTDBAvnGZSmAMv3VT1CXf+2RxxN8Wl5jfEhqJ3IuvoPfiG4+l9oxkPb\ncRBe\r\n=qzlU\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAJ08GDzCRCMdjZD/OqCTcEH0hTBW0EmBe8GlaPVVpWlAiEA9R1qqxJk/ZsmvEQA1nBI7YxCTrp+7Ool1hgegbQtsyA="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_3.0.1_1579640691893_0.10062274309119834"},"_hasShrinkwrap":false},"3.0.2":{"name":"next-transpile-modules","version":"3.0.2","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\""},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"^4.3.1","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.9.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.0","eslint-plugin-jest":"23.6.0","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"24.9.0","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"^2.0.0","rewire":"4.0.1"},"gitHead":"ec628f546bbddea2404984a61a3e43ed83030637","_id":"next-transpile-modules@3.0.2","_nodeVersion":"13.6.0","_npmVersion":"6.13.4","dist":{"integrity":"sha512-w3WsyxvkJ3ws16InHwXhlDaOyG6Peo4co9U2sVBMePwEDo9r3SsbzX7p43sLUTYbpuA2t9iwJoCXkj/4BuD3Qw==","shasum":"b289698d453bb7346fd768da171b53a740bfe436","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-3.0.2.tgz","fileCount":4,"unpackedSize":13627,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeKdBBCRA9TVsSAnZWagAAJXYP/RxvIz3uTW3WElcA/n/H\nJEFpk99GlbqRgsZzSGHjm3pF7b997uMRuZWvCWCTj0ZPMUkSyEOX/CpnlXDj\nWNMuPophM2tNfPO1OEWZ5CwVn0Je1O4fhZV+gLwmCAXkvmDnNVUYWzQVZw+r\n/pWEAS1Styr4VNvb2tlzSkut7v645mzXaJby3r2+disWKtiw28Iripe32Rfd\nVlOhgz5aaK7wd0IXQHHJcgtU2Pme+bOOqLzBebAHZ7Xxx9i8/FMFbM++Pazh\nwmOhRbwy3LEJ7sWEHVqOKiyOzglrYILLieU8Hk5+ZiTyUxOfwVfuvGZRQ8F+\nyKldimACad2lCicLQ/2LhHItNPWG6Ddn4pige7uKMZTUIdUuy+tr9QWGpiWM\nXwyEL71IwW2LedAj2WEDS/LtiuE1wQWUJE2112Qa17cvmKsbDszifQPIY19G\nxOAH6rds2L60fWHuX3y0IsgNiatzyt/SlCtCArF6nxYAvuXNxX77mY7+pSyM\nT5HRplshsRP05JbIH6+ClPtKXIY4TeSJGgWfjmbLY4bZHGQJxOzpbua/Rp4I\n5ULQ1Kfm59sUr8kYZ16AaWdHF2qobuyN2jiiIvp++CQy1jExfzuXf0RuWTL8\nxIDTL5DSYGgrQJxoRWUqc3kV2RmLnxR/OSlxCcFlcHtPLUq1lWw4mF3lLeVU\n604d\r\n=e1wx\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCz7GlhXtd/DjmWAnud2JDBtzSk+UcYjRWeMdRicmursAIgOvZ84slpPuifXCRmdlqKya/1ZJP4ZFLn2FcQhzu5i/A="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_3.0.2_1579798592401_0.21470717396754457"},"_hasShrinkwrap":false},"3.1.0":{"name":"next-transpile-modules","version":"3.1.0","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\""},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"^4.3.1","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.10.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.1","eslint-plugin-jest":"23.8.2","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"^2.1.1","rewire":"4.0.1"},"gitHead":"26beff05e173aa06b13949b3983d8eda7debb5ca","_id":"next-transpile-modules@3.1.0","_nodeVersion":"12.16.1","_npmVersion":"6.13.4","dist":{"integrity":"sha512-3XKIeAyvVcrVHYmXpPcTIFgO7kVagbcMr+BFYe08CwlRgDS3VsPcfyq5shDv6L+72yoE+2Cbcxg4QT1jtE0P1A==","shasum":"1d69ab34ad62d1ae6c601acc04aa5b25f14d8375","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-3.1.0.tgz","fileCount":4,"unpackedSize":14841,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeZ7lGCRA9TVsSAnZWagAAeQcP/jmM+Ot2TCao/kTtdewR\nBPES0XczNzYW4iJnDgQywRkoLRttzteJ56kRYIu2iRYNTsKYU3zgr4ert5R+\nVDgmtbKeQ6vlv4vZ6U7yxBg38Z7gCxMoXWI7/P4H3ux9pitEsAxIvsRxjdGP\nZ/B3M8gQNKdLeCjS3c5dW7Shu1Ukn20ZkTQB/pHXHwsbVkjJUPuxVGo4v7Fg\nx/38OpeE8T0f4OkBPCJS+XoCzFrWJwwUTHktMBh5lutb52Rk7k7Kt7/wYD7v\nwFivsuunppKc3a1Ix1TqG4zZismxaCQ7jz2sF2zSGY6/J+N5u2yg4SpFC/pv\nFW2MR2Z2jBihrbqu6anN9vD+lH8KyfjHLloY31Uz4KRHuwEGPSoPyW2UM/f9\n1CQjgytEIzmwVQk4ZDSAbHMmEnBk8f6Mo98ltqobUZoI/JTLNNOxC/gIN1Z9\nmrXCTCjEooCEJj4g+ZFJGFUxZPRzHvNmnhkYIc59yzCUGzvbH0lF+9UFgfsk\n7MxGEsobl4QnuD+vgpi9vLJRbogm54Zq2P8R/D8qoX1NbG9ISY+4u1ucR4Wa\n1uEJc140/z9Z/ybnE4K/sH/8HqqTRD5ehzTsV55fDB/mSvezXD2oBuihr6fa\nTquG46v+gMCmhmFVTYCtrhcQ1ff9YnQNG4mPJLxUW+R6ZEdMTdzv3w0JAvxN\n/jBw\r\n=S/El\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDbw7gQdAdKss1HcD6Ph1q+eNMdswGGt0ivBznLbfsE3AIgL4bEhUBUSZzFXWLPivVUroPFNglxMlJNXZXQrACel/c="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_3.1.0_1583855942046_0.9347823610418262"},"_hasShrinkwrap":false},"3.2.0":{"name":"next-transpile-modules","version":"3.2.0","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"^4.3.1","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.10.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.1","eslint-plugin-jest":"23.8.2","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"^2.1.1","rewire":"4.0.1"},"gitHead":"4a2525f3307c3c53ada107e0e450746b7e558f40","_id":"next-transpile-modules@3.2.0","_nodeVersion":"12.16.1","_npmVersion":"6.14.4","dist":{"integrity":"sha512-JyT/FPH0mgLX8Pxv0pVfwqQv8flmjolDrqvtP6Ce228vVNPs7EmQd+qYR4kxRdgL2tMTkPeE98FG9qFabTxblA==","shasum":"1e5afb008f839c78a09d66c8379bd5b30cb975a7","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-3.2.0.tgz","fileCount":4,"unpackedSize":16658,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeh6unCRA9TVsSAnZWagAAqZMQAJmbxcMGUCgkyCqFy2ou\nxOnQxxAdPCAm+H9SHKqRyLpVocvMoNtctvVSAVl8sXutA6p1VoU3+2FEbmED\n2hR4udqIcjQvpqt3i4DbcaoSCjsohHjiNo+zRqo5n4MCbTpI9lidKEnuAblg\nYd4AHc/CCkrabD1nW1JrmKHc/UF7/tM51oDT4ziXp6XqP8gqHDqGVsQDZcmG\nbNrePqShyYVnKu0gEfGInWyZKNzMdVprSF1StZ82hz1CQ8VYGBovKyv2rxTJ\n0gKUVXsd0V7CzVG3pOQUvEjNjZkscLZYflFb65xiW56vavWuMl1yILC1rPzg\nTG7/n+mWQ/gVWtaWp1wA0jFk8FCsm5TuybKQ56QYppNATSxZd+bxEi9+G+se\nNDH9czpJxXs26j55fC1UtxJK2DEzx8HEFQ31QujA81b/VPyw9Yfvn6GeauJG\nHAT/giaf3Blw1EOsBLE5pSMLW9P8MagfNUkR/0tTAzY4KNEoHupVa2L9pmjv\ntshZY3ptdI/0sjVtWv1M/UmVqzqn9bpw5j+CNUcysx3UEE00rwA/9cR8EyX/\nyQkA0Imd8kBk3YSWLuXKD1LgOydJBP7d0FfaEVlXRc3mFy2l56qd30tz/omo\nwmeG3vLdvadF8BiYW4QRvXoeuxpygnydZlI1bBRTgXF32KjwhYw4QJwwC6q+\nxTd5\r\n=HWXg\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDu/b51WiGjf4GYvRkZT/2lW2/6Nuhqd86M3Dbv8ZdlSQIhAMOan6Bo+mPrCe264IygsswUq1UundxehFb2YJXIhpKB"}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_3.2.0_1585949607054_0.8146663731813206"},"_hasShrinkwrap":false},"3.3.0":{"name":"next-transpile-modules","version":"3.3.0","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"^4.3.1","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.10.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.1","eslint-plugin-jest":"23.8.2","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"^2.1.1","rewire":"4.0.1"},"gitHead":"dec4023a99883684062f1df21914f9e0cb8b788b","_id":"next-transpile-modules@3.3.0","_nodeVersion":"12.16.1","_npmVersion":"6.14.4","dist":{"integrity":"sha512-QIaBunwtC9oNaluQvfJw5hv1uXSAlTzDCc7/FUxZw5Rnm0yo1HJjW6YodFvA+7Xm9k/2fZV2itF99vMBwTOUjQ==","shasum":"90f197d1ceda2a2ce7a4f423b262320354456abf","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-3.3.0.tgz","fileCount":4,"unpackedSize":16920,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJep+28CRA9TVsSAnZWagAAqecQAItgMguIc6ZLsxetg4zS\nPe/cpmdUYWhWa1Ng1nCPo0Ec613egzojYfR0dZAkYOI5mdi/SELnCzXJTTw6\n+El2bTYtcYao3YwxKR3gaKg/tZTBauhB7z47MDvpeYlvKFWOQG7BQ6/Dd+nv\nNmRxj2vrAVX1PKwC7g9QQANuMy3j3qFvrB32MJqMdU+DlrENfHcnytlxwZcy\nqbHNEWNVc3Spa8O6E2hE8CYe5Rt861IOf1RFCf2kWYfRcPxAJT90OSpAbpJK\nDzN33JnZJ9Dpk9MpIpiRRoOUzVyJoPwaccw/8rQyNMXL/+x+VP18K8DERVIE\nQo/joRjFAbazo3UHjlgKu0lli+AlaRNtveJtnAcE/0km/DYZNgyPPJCFObvr\nOZ0uP2yBDfP7MBvhzplE2djncS3M7Lq2yyyqhDwi8eMzl3SU2TNO6vgR9mKc\n8GZ+RmTP15dBCt08OTAbkdPGYzMffDeMc/WAZj/VUVOT3/wYpJhgHxCdiDnz\nq/ezhiA/DUEJQzGEYRFcCS5i6A3m2cDn2ELZilicHDYxAFmPQqJRAU5Njqy7\nk6EP/BlLMuqsb1SpjDEAzug9TId6kKnXLxGbF705Q/etIhOcDsIZhAnZoe6D\n5ibqRbX10z64GMpqSbPCkekgNJtLAB0TUh8JMgqfgkEq/aQiyFs61dgfkDNx\nYC9x\r\n=HAiH\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC/2Nvw8tqKGRK8Y3aWMvnx7vr0eVAnCYB1gQTAOxb9AgIgF4ZENLnx9kPxMBRn5yn+FLm4olklU8OEnaf8RxbBkJo="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_3.3.0_1588063676248_0.542155466100914"},"_hasShrinkwrap":false},"4.0.0":{"name":"next-transpile-modules","version":"4.0.0","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"^4.3.1","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.10.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.1","eslint-plugin-jest":"23.8.2","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"^2.1.1","rewire":"4.0.1","webpack":"^4.44.0"},"gitHead":"b63a885009a89d09e152f1c80079adf2122eb35e","_id":"next-transpile-modules@4.0.0","_nodeVersion":"14.4.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-BO4MMimk7wsgPkiBGMRzQ4ifjvy34VK84/xHpZClWk7m83uLnDHoyZWsmbv9Qn7BQGmg6Xpl1OarCODhg6JbZA==","shasum":"490b062c8be3ea6b47f69d0bfdd9424957e1cf11","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-4.0.0.tgz","fileCount":4,"unpackedSize":18640,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfHx4/CRA9TVsSAnZWagAA0BwP/0xvMIiHkPeVo/AVuPLc\nwxKeHF5pdTYcP1HAzrsi+NnQpTktaYvsT3U7vvHvlrfupTWqBDQinSBB8hbG\nnWvuk+1Uv6dhijWaxm96uzzFdbuL+J/fOTYIdDO/vqHmxBeA0VLZwMnvoiQ1\nSjbdbyfbqWJmUOMoUYFMgzHhgxiZ4L0sn5Yz2v/x6zs31vCfpRLYDUqK/cCw\nMr3yKnYjG1HLWN+sbqlnTWNKTmsqBLxXJVsmH/IBOrUfEkH5qWuxLG1WhJZf\n009LXpGbzRzCLkOnjttMh0X1zQOxt4K2QEk4uFR7tM3jRpUnbAFA6e6qnu71\nQaJonc2NcfajtuBT0ZPCtaZYv3V4rzfeGcdyKCneWeyFdhVfUNN1ziwzbRGh\n2+xc2DwcyTJQ9FhvBKA4KTrwA2pqkahOxkDQjVvkIzM8oKxFPzasRQiGk8Gp\n3NkwhbzP8HWKGiv4Ifd6HUIHj52q9IuHrQLfZC3z/Xp8QMXu8gjDWyXMd84a\nu8XjNhZeTaFCU0Eh8AnxdtMvUQPN0CHI+ATUXNs9l2BJQc5XGiov1apWBWYW\nzXKoWXpN9wRCAvyKYTLpmmyTSnGr0QwA7kcyedC2w/iJgZhnqgNgR3jLnTVa\nItKol/7Cs1MFGgAvKJL8rV1fSBw+GQgtbswhuLKsy3OIJ4oYW5gsdTTksvlc\nr4JE\r\n=ms3L\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBq4GhVxw38cVcJg2YLeMc3oUw54bmiaKoVQ6UGlcMlkAiEAjOgRuFqQmZ9gOKKeqOqvalQM+zzQkboht4JUvFObUlM="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_4.0.0_1595874879134_0.7981732804602779"},"_hasShrinkwrap":false},"4.0.1":{"name":"next-transpile-modules","version":"4.0.1","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.3.2","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.10.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.1","eslint-plugin-jest":"23.8.2","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"5.2.1","rewire":"4.0.1","webpack":"^4.44.0"},"gitHead":"0b8a51f873463719ece8f15783cfbb98ce674cb2","_id":"next-transpile-modules@4.0.1","_nodeVersion":"14.4.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-WceFxeAzpxWc5y1/MhGzQ5T/utl3teSIGG5OPTevH7TFP/n/QxBThHT6WjNnCd/T9FPQumQ6e/Ia6gL07x1sNQ==","shasum":"19f17943a8af753dacca0dcd9f83b22c2854047a","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-4.0.1.tgz","fileCount":4,"unpackedSize":18026,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfIFKqCRA9TVsSAnZWagAAgw4P/R2pb8sXCWF6N5/35pkp\n4Ac2cDr76otbwLBncvFmMwfq+KAZjYDZhNPfMEv0XctFqguvArhu5tlW+gQW\nyL206KC4X6qLBHtwGcHQ1JuLoaNPkz8Q7IymLr8VgQ79N8W+THiUisOJk2Iq\nsF1onyfXkx1GJLXx8JBTS2t4recjKYBQ2YeWkWNei8j+1TBULLA4Db08kX9H\nzF0/GjS62AEACLdJCfevxP6SRPBXMinpmNAON8n0HM3TIVpG+rbqfu0O7mpO\nxEtRXkF+ZwfrK6eynPHM3cw5ulEjDWwVPzCGwGIa9VgezDz6bOkmaWfc3S4S\nXmjezUhz/HX20um3tBvMh6No2BLctA00tl3etDd9DjOGsEaWFxOfKsGHh0sN\nOgJjm63U713HVzCoMPGI9cNgCcoWodG6SYPyulijq+oF+qDIaxUpTm3D1oBk\nekYtTCwh93tod9lE4SHN8telZQIRXotavzMl0JwnisVn7V+v+VV2+3rjKYsJ\nQSwzjAk8PzM+wc9A0L/n64xgJG0bpl9z80tIikOkH30ee0W6u5bVR2fk5JRr\ncvW+aZzYIDbfFAdn59Z3iR+RJfJ+Q1fsLs43y9RK9QUL+l5oL3+0UvapGbP6\nRy9bgDVH8eezUi1XVB6aqjirccucK/Ab6iR8asFR4nsMO5BDgRrd+5VcpJVz\nklsD\r\n=r7QR\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEamz0Ak3NraGRCKBCtWfLzTuzWK/JPVv9wE6Ww4mbm9AiEAwHAfh0g+v/mnG/wPnlYhOiGj5CpYot/f5HqjMLT1YtY="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_4.0.1_1595953833530_0.4346075690751938"},"_hasShrinkwrap":false},"4.0.2":{"name":"next-transpile-modules","version":"4.0.2","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.3.2","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.10.0","eslint-config-semistandard":"15.0.0","eslint-plugin-import":"2.20.1","eslint-plugin-jest":"23.8.2","eslint-plugin-node":"11.0.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"5.2.1","rewire":"4.0.1","webpack":"^4.44.0"},"gitHead":"b4205ef056fe2d316a476dce4b9c0ca82d567413","_id":"next-transpile-modules@4.0.2","_nodeVersion":"14.4.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-vZSawxOVFvfxEUISThFaixtRIAGQ5tnmEO24j4ifbj/Zs0Bgjhr7W6Uytf+10cUuyEEQxi4CEb6t9e1aKc8Ijg==","shasum":"7fdb9e42cc2fbc1511d4ae008d73030db2885aa4","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-4.0.2.tgz","fileCount":4,"unpackedSize":18099,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfIWZ2CRA9TVsSAnZWagAAtiAP/2aPxrX6FRYik6sGqCXQ\nlfdzHiedvahMHVYJZvZZD3rQ6dPvu4KkmDGe4RNQw+sy3jncfJkhF/TsUZwK\nD/z9CzWmDiMK8z8H/ZQ5wMvm6Mvmhejjzuu2GFt4keB7Nzlz4c3Sa6iGBmjF\noLdMmufMnPMppn2E5BQ3CjLy3f0fMmNkA7ycQDpk9SO/DzeKreUTDk+KepXP\ncGl/8dxCEUD/37X9DOd+5l8hlsd7FC8ySST3h+rICYHy8ELJ40TGPvV3F2rF\nR7Id3206xxiF59YgIQIp1FeDcgfHgr/jTI29ffT1ileYIc/mM3t0MtEcS4F7\ncLKyNztGXVyAD91uaYvd2yNBGpyxRCkvmUPHRm1Z3I4B3W9YybtkTkF7GEH0\n3Y2mDCkdNoAAUYTMEYvdLPWckKs1GaKIqb4SZ4XReSDNifUlBf6uJebbt1XD\nTBhIhbQbToGOYDtcP8Cs0UBKrquuvQQXirIFs3dwH/VynX/Jj3Z9nnQw1gvV\nOtn05odXomEGKHyKiCiHyq3q+xaYqhuGtFUzXzcsuKP5lZM1sKaoJp5KA1Uq\n2Ove9QHRlk2eLsrzhntoD8Sd6QeETyg2HYrDAyDZTZ8n5g4z8765CqPu9gXd\nVcTbzzG3sGtfs5LfnJ1cZn9nMCbsEuCOGDHhgsr1RB9ORD/Pi5l/ohZcx8uh\n0NIy\r\n=c2Gz\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHTg3J+H+PIYHOaUt0gWnv5BybigCJq7cAVJn7I3kyfeAiEAsC/JJTQxT1Z3RIUE7phNZvbuqXBYdTXBppxE6zJ0AU4="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_4.0.2_1596024437577_0.9980788442578559"},"_hasShrinkwrap":false},"4.0.3":{"name":"next-transpile-modules","version":"4.0.3","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.3.2","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.11.0","eslint-config-semistandard":"15.0.1","eslint-plugin-import":"2.22.0","eslint-plugin-jest":"23.20.0","eslint-plugin-node":"11.1.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"5.2.1","rewire":"4.0.1","webpack":"^4.44.0"},"gitHead":"385d34395805f667c4f5b657addbb8af1ab1d89b","_id":"next-transpile-modules@4.0.3","_nodeVersion":"14.4.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-S1/aM+cvjIfEDofPS2yqbSQ/ROnifF6rFtZ7GaLni0wBfjHUjfPJnhG4Sy7lxQOA0EbFURR0l8Rt9ivGP4b6Mg==","shasum":"d61e4c9150a2f2d0ac703dad806007e60e445bb1","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-4.0.3.tgz","fileCount":4,"unpackedSize":20210,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfMrq5CRA9TVsSAnZWagAAz94QAJNXUlCMHoStRuGC+RVb\ncfHPX+xg0/jSttMvYVozzdnjmab2sYt4wdhEXRWxrNT3TiyMXlLUjw2W9ZzG\nZAK4pYcu/OYqp496VT0Ce58Q01DdH7l5m8WSSXRr8pF9g6A6EZyM8J9CJSY1\n495Dq5419WkkhvAFSrPGY0M2YP2I9VJDcl697RsiYtXPnkmizj1DgeOGgzoU\nDNr1WSu33zxmbrxBnDp7F+nuoZAd/ruIBJRbcdu/IaFsAJObnLkqDTQ/5mhj\nEuYVueB20/BHceBXy8JI+EteJDYblCH7T8LV/ii0SZfHB8i/jHXuGFC70JfB\nDtrj0L+dOEoLYr9+bxsGk5bm7F2XkLUfGzW96Hacj4QAqEf6rRrAkyhi1tRf\nPmJwYaOzxLLXjgYDQzpx27qGODc4PbKixTGEzC9O3mp0zzwI1LS50mduXmIp\ni6eTOc5gvErC7Y17UfEugHcZy5tX0+QKSqaxHKBAFxgK5sGzGiJ2An5GGFvW\nCiaEthuURfYMkjFOTK5E5LnXyrCvw1u/NydoKiCtfflF1f1bxpuA+ORpTXme\nXj0GXd1Arach2AdQyi/YIztt75Cf/oc5Gcaxz/i+6gQ6LhD82Ql4h5kDJifc\nMUoKZ7N+V/9qFirYGcgS1lS4qnPzO9dZVmCrQE53BhZX7RpO7kndxdY053LT\nkvAn\r\n=hEyJ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCaAi3resl5hRv8sqCskiELiW80C00BzD4vzS8nBVNUnQIhAPiGbxGUk3zC8HrpeOTABppaVJ0q0FfkqAoJHu/QDC0W"}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_4.0.3_1597160121311_0.20645318535691448"},"_hasShrinkwrap":false},"4.1.0":{"name":"next-transpile-modules","version":"4.1.0","main":"src/next-transpile-modules.js","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","scripts":{"test":"jest","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"micromatch":"^4.0.2","slash":"^3.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.3.2","anymatch":"2.0.0","eslint":"6.8.0","eslint-config-prettier":"6.11.0","eslint-config-semistandard":"15.0.1","eslint-plugin-import":"2.22.0","eslint-plugin-jest":"23.20.0","eslint-plugin-node":"11.1.0","eslint-plugin-promise":"4.2.1","eslint-plugin-standard":"4.0.1","jest":"25.1.0","jest-environment-puppeteer":"4.4.0","jest-puppeteer":"^4.4.0","prettier":"1.19.1","prettier-eslint":"9.0.1","puppeteer":"5.2.1","rewire":"4.0.1","webpack":"^4.44.0"},"gitHead":"c191444864b5398330ce34b2bc1e31ab4fd34742","_id":"next-transpile-modules@4.1.0","_nodeVersion":"14.4.0","_npmVersion":"6.14.4","dist":{"integrity":"sha512-brb9S2Dq7l01fV0fdZw1pO2cWMu7fFTclIV2nccmX2Jzwtz1c9iScPMqGyWP6/wglOPOColoJlHzOrSG6cnEIQ==","shasum":"b2d4bd29f3d4179014f7615720f360fdeec67ff7","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-4.1.0.tgz","fileCount":4,"unpackedSize":20972,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfM9PYCRA9TVsSAnZWagAA9vIP/0ddiipPVpGhlHwhwRKo\nc7bl4hfhqgOc5rv7jx3WMK2dukjdlPzxqXiJmi054/eSR7Y2UwRPJ0FWG4aI\nsfiVfT+koxUZYydGhUdxbs44npW4g73sc7T/6uSUoPHWui/e6zoXXkkaavYX\n9LwEPdUgJjIDGNvMOaiNyStjdZ1oSPFQNhaSE81QrIgfCYzZFQ+uH4T9e39d\nc0EhzkdQ6nmAkQ3MVbiQq69PlVdZtx2IBrhnvzh3DNRhM96MnyMi7L0PZh81\ntN6bSrBVjcP9KgmTM7737Wq1m8mRSNqzsuyYGylStp6d5Wy1ToHmBo1LYCnl\nsWqy9HZrnR01o+p1sIJtriPovmDxSzHXuCXKvQkRoz+VF2ComDgNakMlmqfd\n+Nd9ds3zRnseUButTuvAxX7if/4jOMZwHxo4Weci7/R4UPoxgHd/EKB1OdaD\n/Tm0pzH2vj92OIMdVcMli68UTU6hwtrJBB2tbZ8qXyfkHwx41yeYFXD9mJPI\n2zQdI0dcGN00KcJsVcUhFmPr2CCbvkuacDYbipoCwY76nUMYbaYPtxevhW/h\nVRIsEcXIDcJ+DuxLjwAvzh5YZ/N48fQqz4SZLZLpBfE7qoFeo6sEE5rOFedo\nqFvWUvvW6DO4YWiYIsgj4cdpl3v3G3LO9X7BdI4D1rJP5++9MgDGOcXdlRBr\ny4dr\r\n=Ofwk\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFu7yJUoCGDe3OGPOoQ0bOSxskcdS51ghYVoiNapFZPtAiBFqcITxdA7jE45uLTGX6vGLe4xEv+4RNo4OVaB4MqKHw=="}]},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_4.1.0_1597232088221_0.35469295039464677"},"_hasShrinkwrap":false},"5.0.0-beta.0":{"name":"next-transpile-modules","version":"5.0.0-beta.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"resolve":"^1.19.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","anymatch":"^2.0.0","eslint":"^7.12.1","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.0","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^4.0.2","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.1.2","prettier-eslint":"^11.0.0","puppeteer":"^5.4.1","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"d7445d58f89a1f7c050c56aa111712edeac87974","_id":"next-transpile-modules@5.0.0-beta.0","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-rWXIY8NOZyHBQEO50l5CoaGofSbX6zC9SpqSgi+28abB/bSzvBvF7nZoNE6Y/iIRvrEhH0AgaY5Gif7Y1oFOyw==","shasum":"7410b4a2cf687a8a864a2fab623a2bee21829030","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.0.tgz","fileCount":4,"unpackedSize":20365,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfro9ICRA9TVsSAnZWagAALssP+wX12s+GC5cyhsr11xVb\nmuwozHr04nvz8k+OpuR0Gyfyzx/SvD2dCy5E9nEzEpQWV+ZHIw27QkYYTfQ9\nmb9j5KBil0ad2VxB1EC8K0ZvkdcE7UzwoFx0we2uFGW59vX0P0z6kS3MSmPo\nZK9xCE6SJH3lAElXYnp8DH8PGtI0wx4gWm5wjP9MfHJIVO2ImP8VRjNhtNYL\nw88TWyYjGtWZmTp2mVy93iaNKjeQtyDFox+oCqI4bvPwrcQzuRtaxX0HWhz9\ntf9eiowSj5JRATpJecbGqjtqloE0Z2rQtKjpsK9Es6POA0MAJqPGGouDTj+H\n25vttXsU0PSTgKhcJZA5LIfw9fFTQEm6I8ugZe8km5rYH/K8krrSlmbsDGoS\n9DVAi7a8SZIxXYZIzz/xNTkJNYPCXJvz+z8iX0uG9y/3uAo3bySSIrcSM+Rw\n0O+g0+YSPRrvs9xQ6hjmCPycV4JY74n2zzS8yUI4WYqa1Sgre1tGwKytQJyj\nvLIIkEAk4IJN1SYhpLyWbOFISlXYofXUYvxHqRfIfa1v6oW7hUFr/9bwXPrD\nIQzgU7nD1437QxI+3YXjPZjYIgbIoYaDgsS5lhssn/o2lSzI1aLWdIFllwX3\nINRxMrBIVSkolgJ5kqrW/NjvMs8lNmhv7uRWJY6PMIomD2TY8bZopQoFnPu5\n3Wsx\r\n=YVjf\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCy+M4AqvpW6Bhm4K75w62zKf71PLsD/U2qCoty5kD6mQIgS2/WtibEgjecbgW4oxNo5Ixn2hvH4IzkH7myWfTsHT0="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.0_1605275463644_0.7490347776062045"},"_hasShrinkwrap":false},"5.0.0-beta.1":{"name":"next-transpile-modules","version":"5.0.0-beta.1","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"resolve":"^1.19.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","anymatch":"^2.0.0","eslint":"^7.12.1","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.0","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^4.0.2","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.1.2","prettier-eslint":"^11.0.0","puppeteer":"^5.4.1","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"337aef6d7655962764449dd26e44dfcc15c807cf","_id":"next-transpile-modules@5.0.0-beta.1","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-9kKlBQMlWDbpie6l6NZNH5v9RTGgxo9B3GOFm17nAcSWmPk1ROAxOEA9UUmnRoq8jKFmF47z0K/4ZCnQ1giM3g==","shasum":"6aa6ce5871889a636e512a6239cc1801207d6446","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.1.tgz","fileCount":4,"unpackedSize":20624,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfrpJ8CRA9TVsSAnZWagAAhgQQAJuBc/2gFduW0b3QMsLX\nPtXmEF9fh773/e2ePhuicVvwekCNzOd+2+xWUUYbXxjs/f62q1nAJGF0ngW9\nHZsr5l2EeaoUWDyl+t7yvuug3ypbpIq85tHG7xrWEU5z7nKIx1CdLJirDubH\ne/VVWNhno5q62o5fPubQ4Kfr8sdhWXZAADdKFYhrAaW9q8yVNbsWJq02F4tE\nEllTXkf+FRVzZe48KQk5cAT0JLZAZpMk16nfgCahe7J5Zkxecx7pgWHlnGg6\ncAi3ZGxNxYQ4h9Ot01BfNRJOVM+D7WhU1yPWkdao1CuZ01KjwNjfCJHsgYrH\nu5MvqQSw525AO495eTsIZ++uWlUPW2hRcsM5IVEZhTqZL1EMcgwa0bTOUaLd\npfqgARUTa+Ca54AufAWxUzr9DhOYLRIDwIu5SqXzLPmNGawzSCBc+gu164xQ\ng567atx8eBpThO8as3IHZkX96cvZh8wFSMKtqkTvPFZgLa/OG0NsLyzD60L2\n9OqOA3JSBTAGxnVcZOzaft5li7x2Ed+LPZlvT7se3G/jSNgIG0y4zOMvyGqc\noEdT33V97HjNySSHuHDrs/ksOD1umDgdbKV8cgDiUtEBfkUwcg5Zf/PHdLpe\n+JmapG7sAuFtY8CIcBRe4m0AukNRksxlrLe1xY16X0W7XVdnh2Ic7Lc/j6/j\nC+0i\r\n=zOZz\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD1vcWejjBv3Ya4lfCokl7EX365WWMppQv/fKBrqqrBtAIgM5XPYWmAPIz72hAJrz8sPqUR3NQUJp93WYz2tVYZpCQ="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.1_1605276284157_0.1923104659987549"},"_hasShrinkwrap":false},"5.0.0-beta.2":{"name":"next-transpile-modules","version":"5.0.0-beta.2","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"resolve":"^1.19.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","anymatch":"^2.0.0","eslint":"^7.12.1","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.0","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^4.0.2","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.1.2","prettier-eslint":"^11.0.0","puppeteer":"^5.4.1","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"cc6f55e57a980444c4583f87a4dc88df3b5522ad","_id":"next-transpile-modules@5.0.0-beta.2","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-vc+McJunLmJ8NQp/wNlQjyejtfdjybb+RQuypiQCYSNafifZli3YPQiWevjYxt5KGXTKH1Lj77l+mAKandXlyQ==","shasum":"298c8d888f430a055f97ebdcccde194ea7ce523f","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.2.tgz","fileCount":4,"unpackedSize":20650,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfrpMPCRA9TVsSAnZWagAALc8P/0vzv+p18g62T9Xs7Xb3\nvuj9BXDKT5lkVaXpL1mslH3wCYPsK8C1Axt7AA2Vd6srXsBIzC8s1k4zExon\n7eWGvUm5gsRok6skpzCRnJbe7iGK6Ixmjz2TRD+l2xjQZZ/jql1XNDPbuyhH\n7lyIKmfNVHB4e+zvOpiVrefKxzSY36C5br09MVsV92vMFXMvGtnpY7/e2/ws\n+1wIxvmPA/FrCbSd2ghjd1DX8+rMJYVkcvX4izVNBtARaElmgmYDVN2KDtty\n5zAUnweF7B7amHCEW9Emx6t6X+mzd5SqvW77Z77NRFZoFe8TvfiKYtW0LyB8\nYfWNd0H0B/vYM4TFEZrFtJiSbnLuG2xYDleGzcJa333fgXB9HSnDTk08EoFN\nXJAjsSJZ4HnrGw5grWF5elfZ69WzlXM3o0ZW7CJ/7KB3QsVNnqlWcyTH3k6/\nsAx27f8nASk0mDK10blughKVwtR3SJT3m/dX5UtYzr4QudX6Y2iViTRqVidh\nxOUbCVKS+kcMVW+qzC6WkGyP55fyV+shPZ8drIUno3rJHsuPbin3Zop5Fh4J\nacV7R/p+ZeZhWPz4i6r8XzdDqt/oh7IbeLVb6eSdR7eHDJp1zHXKf3puSLGR\nLP4Ff3iwYBI2sbW9EyxknOvo7N9e4fzAQ+BklBeSZyKnbaxrdEBArhOg/jby\nJfbn\r\n=no+H\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDdCaep2+r0oal/u47ZxsFa8x9FoeRYnTd2rRp+fnnl4AIgDJNolWEyn4gnoxJ97Hw1tn5cB7HB0U1RrK8jdIGQPdE="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.2_1605276430659_0.6282906052914965"},"_hasShrinkwrap":false},"5.0.0-beta.3":{"name":"next-transpile-modules","version":"5.0.0-beta.3","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"resolve":"^1.19.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","anymatch":"^2.0.0","eslint":"^7.12.1","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.0","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^4.0.2","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.1.2","prettier-eslint":"^11.0.0","puppeteer":"^5.4.1","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"f0d50519ee318aeaaade21807387949b344c549d","_id":"next-transpile-modules@5.0.0-beta.3","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-IWqcFTTlDpgiR/gW88SjCD0Ub5N2TwAsjFneCiA7GhCgMxV1Gi2ZTx2xxs3xQeBvoYuHAjJGo+3SYh0nDZUxBg==","shasum":"e3d34a76f2d8751d5200d448ca4bc1de6f4a60f1","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.3.tgz","fileCount":4,"unpackedSize":20567,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfrpd/CRA9TVsSAnZWagAAjdIP/3xlNo5DtI6woLd556eA\nYyWqzgfTbqAN6CdpNGeY19kKi55NLj37azUCyvn8BlQQatllpxyrUi5R0LhZ\nFZAiGMwxzBLOC/7YC/5HJRAomcxfYa7zzx7wRXJrVsMyONbGjQslVc5cFSjy\ngmOGWFh84WIitC6z+JZWQaw1q4/oEfoNvHn3db/eOirtnMn3sncweZrL1XBX\n6UaTfs/R3zbJIQI9y3ncJHiRZu4ez6Vksw18tE+2qZCo366p4mPNklIRwpwX\nylKUgXXhDfmORWq0PcmJbyCKRKtD207Rlw9KTF+X/sg2rNcOKi1jirzQLFTN\nmFUnPRFhZ+WXTinPHe3zXpQg085jBnj7iiSehS5hPgRGeq+bMEf+SMLClfap\nDvW7BbZHAlX7omoI4LyPzwZwigM0U46YUI3I2+f0uAILchSNEiAIqwMqNWKU\nEe1Dh6CRrdU0n4ERoMaH4EiKhPoRDh5EWtdY+JPvquMl+xNCbUAq1fFRjv9y\nmF1F6UU1Z37mx6aGiJk/1FxL4NEsVvUFgg0fDqIFZgKUhd5N2GYiqU35rkoi\nT49MN/mfA0hQcNilDbKJdZxRLiFFLvyPILtukcgzddCMyOnuqjdsy8fZDhND\nKwRQcPYNfr622vK6H3y33N/cmFlEQ3mFsmS5bJhs6xSvxehA5sywNKw41Gwn\nout2\r\n=y/mS\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDzT1ArKciRDSr6qdVOCo+UrNTAiYjQER9nQCW+r4i5zAIgXWXTOvYg+zS/9mtRHooDSc67iXELapGhLQiUxhrC/iM="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.3_1605277566847_0.20988654007078056"},"_hasShrinkwrap":false},"5.0.0-beta.4":{"name":"next-transpile-modules","version":"5.0.0-beta.4","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","anymatch":"^2.0.0","eslint":"^7.12.1","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.0","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^4.0.2","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.1.2","prettier-eslint":"^11.0.0","puppeteer":"^5.4.1","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"47a60f87cfb5140e1f5dbb68ba713d4ce2c0045a","_id":"next-transpile-modules@5.0.0-beta.4","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-oX/1d2insuEpdUYdWCdkADpAftUZyyLMNbw/GF3aMb55WHcvnDX69ScKNfS98od3Nu9DXuoIatOL7ZUwVC7wdw==","shasum":"6e41b6d38e102e2c290978c2e159bf601a84aeff","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.4.tgz","fileCount":4,"unpackedSize":20678,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfrqjgCRA9TVsSAnZWagAAAjwP/jC79Y1gmT2Ufg40PMzz\nDLvDKZnIVBmJHPQfJo9NA8omZjc9HWH7aK93ysa+grRp2ysnb1miS3dMzvXi\nPa1ltl+rGOzNwkS5AKtm/xNf/VBYgVJYWzjKNkpWZh/xrHMQVd8ihx/l/5f2\nr/gBMm1uRmDcx5Lu7lESnI7UmwxFKiLW4SoJoPdDTmIvm/S42Ak8nPNg4c4R\n7oQ4PTaCmbILLXK6ISZqbnkTl792xR7rPcDjMD5JuR7zry3RRkycHKkfmAGt\nMkdiXocpt8XbhZaBusuUnRAkiXAwJ+Dhr3t+t+478snay7Rm54nqqL+irN1p\nOIHLiSDqpe4TXBAnFroNpf0z7mFpPCFlWoL4HGd6Fxggg5sj6L9vOgWF6vFf\nfImdnsl2S0Yl+OJ40hilrYSOkXZ9ltT9Gb0KYMJQ9adMD5EOII/wY1JSRaX3\nv4yM2DLv/MntCCyXiyh92tcVExr1IGykpkq9P9eNntqVwnaVgn10n5HDYLBD\nUkw65nu9QIeblSKCObPp5ZO7x9v5gxqDmlTkVcPseGA2gp705shax5TbmCQk\nLdh++qczCx6VbM1rB0j3CP+ywh5azTlRiNnjiUNpWMEKB1PUg8oRJHZP3usR\nhR5CJKGiCXkWYgLOXo6pvnAKbsI96i8UvBqrgweP7pRsJjT2hHdF/CCUXJLv\nd52m\r\n=frrO\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAKaBxV6k0ftSAKoWzMKX3P2EDTmOXew7TKxSzs4sbECAiEAgyNOf7XQStGzhoVX61DYFpVxIbJKS6fgmnlJtBRJnUs="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.4_1605282015938_0.9143134252124479"},"_hasShrinkwrap":false},"5.0.0-beta.5":{"name":"next-transpile-modules","version":"5.0.0-beta.5","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5 run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","anymatch":"^2.0.0","eslint":"^7.12.1","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.0","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^4.0.2","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.1.2","prettier-eslint":"^11.0.0","puppeteer":"^5.4.1","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"e76e2129ea7f980bfc806885edd5a1d0e5af4368","_id":"next-transpile-modules@5.0.0-beta.5","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-welKEOGb6gU6RfixRZcDsFavcyfmZeGLXlNexvc2ApmFHS5EeFJPwrtLfrLqFxYQ+RkFZkgSW2vl8vD+poo1cw==","shasum":"5b361258d7ca7881317fb23e3844b0cab487d959","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.5.tgz","fileCount":4,"unpackedSize":20769,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfrqrECRA9TVsSAnZWagAA6UEP/RsXiB2c1lKAMWKhc/GH\n324EqC0MZ1s1dTOOYgHNn1m/Mj8dOGYlZLfPXzT2/dIeHQ/wftB3S42+QQP/\nfbDuQDPOp6NPYhnJf7pKhfwwTGI2AKyrt6CF2nePBv7fGXUXq+DTdIr4iJAX\nvVP9cw1bHEp8ekdd6c6d2JBvhmxuGGRs9bly+s/04FDrXrzqIRPbMc36pLk+\nxHmg86+4sUbNpzxAs5pbZT9XyG/j21T9YOAQyV9VJnWNTffuCSsENKFnLh+f\n5j7pB5LYABBfZk7re4r/qYeZNBtge7aUXa8KNHUQmOUbKbnNS11m+TiB5RJs\nSFrEWbwFO9y0YYFmEk8usjxKvtDBQko/K7lLtyquNPhR5sA1CG6jlQTo4V5w\nc//E6PiyhexhlS9pxBBzFjheB1Jab/yLyeQy1VILf1AQ30GcA7lmAQ+r4zN9\n49bHL+SbeSRAlUFtjRL4rg1ZKq7+xlz4rxuS1bsmuIJJcy6gQ3HsE9PaAtSW\n1qK7B8tzXBKfJQWPbW3qkJz0OKUh8SOAcaClGmtL3WgcroxkAL8pIm7CXr7O\nTUqc3rBgm/4/ukYk1U57JW7D6eVkITwxLVm062yT8mlb/8H+pgJIiZO8bFJe\nk3cOre0ZEn6H8NgrX/GImjXYDMLshkAptZVEiUKsvvapsRUaIYXcBRrUZfVN\nUH7U\r\n=n6NY\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIErveicJcTIG2M/+l+I/iAweR2KUUHhlk8MSJm7XZij/AiEA4RV7NrEIAHZXkonV/0ZStpy0U+EvNdSTlKevoRSZcT4="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.5_1605282500045_0.8020341016378525"},"_hasShrinkwrap":false},"5.0.0-beta.6":{"name":"next-transpile-modules","version":"5.0.0-beta.6","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.6","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-k5koE5FfxfwYXY+r4Nw0mtoWWvGweRC07b8q+lU7/BQr02vHr9va7LhuAK4kqZqR1wx682kQO0PCyR8dfxqo5A==","shasum":"e6ae2fc2c8932a85cf04a0589b33a15605087a66","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.6.tgz","fileCount":4,"unpackedSize":21966,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvk8bCRA9TVsSAnZWagAAPYQP/23+BZiwyHR6XIMlxEw7\n7Q5iCzeVENNofX5scQwwQpzOj9egOGBdLnUuj7awg/bRA3aIZc5f2HNmgLZk\nDwssBlT7uQk6cJE/KjSeqAJUV8/F1f+SPB01pwriTLKywcF2bd3w62rrbSjI\nLwNg+OBGRTlcyIljQlYdkhvaanaUeYRGylW99fs+cxmNo11zjiVxQE/r29Ep\nBIfFnZK156MbCCF8Ug4qCO+X4ULxGe7Q/82sMDMRUW1edOmf+X2M+Z1ORJjh\nEArolbrKVdKeXJ8uMmIJZedK/N0WKfJX1IRIkldCbH7qghvel//yp9yBSlRS\nAkL5po82tSg6yeMGox6j0iAbnWOgKE/B06zDw0MFA9+cN4OAF5pIor0NEZyB\nTQcwHmaYzBpvpnse7ldXRJrZnessoME4aWkyntvem/ibxzU5STlvSK7a+lHl\niaVpPrHwurLhc5wSmUhZnqV23mwINQc0NniDjHd2Efz+QrTv/Iy1LH3AaVq2\nX9mgiN8AnrGhhXCDFo3DdcxcI4wKh+OBj/8CldtdLqpXLDPh7aW5QeUNxYzf\n6UKD0gWcREaaYuuuNLj0XpdnL8xGoUUDSrVC4IYcJQ1H0bLGD7Y3gTxVxNDn\nhhw2aQMd4wD7dHtB/4i2ycUyHSp8/qekdqjve3yu0ByENJ6mKZEd926Y+ltF\nAbC/\r\n=1oaq\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDhHVQBLngv5ltpY1GeopbtnK3DIuYYZeEwCetJX5xHdQIhAIHTsNWgTywcXBxnXwGbF+rsB49CP/oOY4PyrTPJ6GSb"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.6_1606307611146_0.8377772869428217"},"_hasShrinkwrap":false},"5.0.0-beta.7":{"name":"next-transpile-modules","version":"5.0.0-beta.7","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.7","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-3nJc7QblBEph7GZBx2YZfHayI0P/s1BFMP8CKk2kCAd8SGtymLhXBfb0ox6Cw075/fbLCGUbOYWKNiO3az9rYA==","shasum":"206ac2ff72d6a7988ad3607e11c0b4dc35d5af23","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.7.tgz","fileCount":4,"unpackedSize":22075,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvlItCRA9TVsSAnZWagAAk7UP/jx14sgHk3td2ixKc2uK\ndcvYxQ3WapLaOZg+rGx90s7sGVXUj9ck7ETAheX71xx5fx9dGMlkMlLcrnPs\n5MqlAnxi8SniLLzHVgoTfOM5rNolQmNrij5uOEis5+nhNTkEvxrZ7YF0yzWj\n9MCs+NO9hQYvNMyalV7ejpZ/L/6LoO05v84RKIUQUreEq/NzMPd+4tKmPF7o\n6GidnX7YVjwcRIGgPDTkIXF1VyJ2vwyKbPRrHIp59COC2r7wA64R7Yqmlo87\nDg5mqS9qusAakmRsAZsBtAEG0OyMjo36bMttvo6LbxPKfrRC+R0YbAOWK+id\nFUsRUfzqT9xkoIeTMyyr0G3ggDgX6V33rdIMxC8drcIQ16acp2bTT95isdj4\nUtS5c36HFeoHMO/o84g2S+5W4x9uKVb43X0F5PSWBHabxxx3G1y/UEOelRjS\nCtKX9J3mVdMMquF7nA5aKgEbe9j+nlMbjI2dDQy9uyURVXVnmpxuJ9VqtDRc\ny1XQgPp/g3KNHCwmKmQ8sttyr5Mf6PUzvEbRt8984RINT+/hj2BY997EQ6YW\nhO6KOUunXaIoxN0gBYPLnW8INWp7yKvKaHoLI+ZfPNX7DOIEfsxuZvchsa1k\nUU/ktnOiMPV41fS3TuAC0czwD3yQ4HaKaR9NInwlb/AugBV8XTSiqxtcmJZp\nlVUX\r\n=u2OD\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGFNg+G3W0WjYBxEfD3XnEOX6cpPTbbRrdGxQP8sQxe0AiEAqKShb4MDaZymoQbZNcXo4BDSWvJAdgmtZb47/n463WE="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.7_1606308397564_0.9595136824411445"},"_hasShrinkwrap":false},"5.0.0-beta.8":{"name":"next-transpile-modules","version":"5.0.0-beta.8","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.8","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-4GmmPooGXYeElmN5dgGSuQ9VQXg5OPRtx36ib55ibiIbTbHwPKmTH7VzOO6I8B9DWjAuWb+ig3ddMFUlVtENWQ==","shasum":"048b16547cd8a06872305971a35aa752febe83c4","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.8.tgz","fileCount":4,"unpackedSize":22076,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvlebCRA9TVsSAnZWagAAdQ0P/2Itfwn14y0z924ySIOJ\nBZwFHwp6oVIfrHZZnvPQMPzh22Sa4EYQMQBu/UWss0rFtr5Klq73FN4y+etk\n0otduKLOZhYumdGUhTMoxfXfjzxdrSx1pdbBnahApmLnJDqzQ5k5tYeO6P/X\nZhBw+FszU8vDCPcn5GIpYgcbmC2GDYD0qVFGXwnhEB7MMOS8m5PO5e6FQ5+K\ndiIGCRbleQnA6F8AeQM1PKPd8YGgNFkHvlaMmvjJHZbnizW9hLD4Ibyy3xoY\nUEtJvmCKssCgiINSPDq0bUd33LSgcDuPhKfxJhDSwgre/bHEmcGlqrehOlce\neaLnDwd02xKGQxxSoWAJrOAEsOKg+WeMWCMsj4YKvDa05l/VikfvHWNW2dCQ\nSIHp3Hg7dkvsQZbSzKjW52KwXHkvs45jsGbd1X6YYSjoviyS6woesvPhEjvD\ncga0maCjd1FnZoZI16Aopr6mw9YqVy01mbv2AEML6vy+Ka6pjulg0U+DvvvR\n+qWdMmHY00yXkyb1LXYIZeLD1BsESGKUX3mzSvmudcPgMM7lxw8RFRUjU27w\nd/YTGOszzLSNwfoHcSt1L9w18u1WwgnUA660d/HXUnnz8uGPA7S/7A80iKeH\nqckB/bSxf4ESLBjqqUWAcr5k5eQRfcn/twCfnuDaKgScdrMZ0jolIhZIcrca\nnkkD\r\n=NCLT\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCSl0Yr5s34GGWmUaRkpbzuv0owP0K3Gd4rZLNojXc42wIhANrhFLQa6InMJSGrvoVCbKq8fXbFdkwE5kG7v77gMeWz"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.8_1606309786893_0.3291284586376215"},"_hasShrinkwrap":false},"5.0.0-beta.9":{"name":"next-transpile-modules","version":"5.0.0-beta.9","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.9","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-cwUz8mLncvvLCO6nmF/TQ8oM5OtxhQ1paDB/PLklewPA2U047M2kaOpaTlj/UWNPa5VdzmyyJa50ZBEKWbYZnw==","shasum":"a5c579f2b40c11ecd10974f9c0f5ea74a58ed6b1","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.9.tgz","fileCount":4,"unpackedSize":22114,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvlhwCRA9TVsSAnZWagAAaf4P/2ZfqDjL3NuHLxqJYTvK\nGjC3M65i+8bw6puVvS0bQjQmeOMckB4mVH79S8HWPtTZE4J7vsWD3BGPr2OR\nGoPEH4iMO6DYLfdxZ6CwGmnc4M3YfF5fHvhiaJ2QWZDKSCC1etO7199Mw2O0\nItN0YtH6yDnDQuyltcaTQkip4waB1anUdu+I8g+jrvnBVyDXttFAEs8kFHhC\nWVf1j3ialMYlaMIVDZE/F/rabwRq/+OX3w1JYsl5jQrDERkknbebTc0fDZXq\nxwehKoE+HBE4zSGHh7YO3HlUuukVCIMHDbLgbxHFauJ+Y731mPFmhp8ytlsz\nwZntIeByMnXgkYoOHE+g3ir4rdkBD9yAwKXEyLMRkcbs8iHOPOb+ydXYLy6t\nyxVAQay3Ec7pScU0TF4sx+jk4nLWwtMvNqlfGHA0HqasTVikhxUlXovm1adQ\nFyU+39e5zeh219u/rZpepYbBBg/QOzyFF242xkBqxMt+JIXarsz671TFTfO0\npFfbhW/oAmrzuVPfWlAJk3f2qOxUtPTOCxR7VLSKex0LWIk7wSL0wEzNBLbF\nujKKpiHeoCPcO+E10EeSE8PlU94XclL9V7A9Qt2POz3zIjnpF8p1W0OEUelx\nvprGxPOdgQTXQM0RC+bDWgxD6Ihi4v9AZHgdtkFhPAFSzznmxdYcPnXz7GQ5\n9RS5\r\n=yePj\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFCf3JVeAs2/+USngetO7qO08kZuS9SZtANTHEXw4hqgAiAe42mMGf+qqYJ2HCtqEacy/9NBZ09Ngl2ymSGN5ANshg=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.9_1606309999880_0.5329191799494135"},"_hasShrinkwrap":false},"5.0.0-beta.10":{"name":"next-transpile-modules","version":"5.0.0-beta.10","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.10","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-kAPBpwNIxD/PeG5u/xpsvmdYm/I7R2mAU6iDPyEjGObJKAeFZBtYuG21f9117KTvN1hJBV870han3gKwSVwd8w==","shasum":"5a2a5c29b6c1e8fcfeecdb9b331a741d23ce0b41","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.10.tgz","fileCount":4,"unpackedSize":22085,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvlxMCRA9TVsSAnZWagAAU8MP+gMTIRMIuYPopJahVoRR\nV0lT04ZdaEBO7C6Kqtz4gg07hOzmtUaxZrvo5xJw+dxJbZPr/pep/ByFjULo\nHNA+1lLZABELpNfoKeXCiKNJYjx3inFNZxg+ts4hMZxzpT5kB6dUxNil+scB\nKBZ/44HCgmC7qPHgTZO1WQyKxTBbWPCtMZ/8hrpk/XbaKusaXy85gJrzEKk4\n9iMCYqLn5jhmNTZJDW8eLJDU/5WmiMzGXZiE7o3rPCFZgiZC4hEOczDGrvsG\nwI5riXBjILXF5jTwXt/O+uJP/K6uHx58gEhnOCnXt14MBdTZV5CYAD/uNgzj\ndNuyXZ4GiIBNsDOTCwD4ktsCqZqV2sxelDumYlQ+LQtnIxyONgAsYQsZKq9T\nBYkZaVmn0hA7/B+YLXSpXrogMKNtnq5bwL48nglwigbinqRXBftwkUsoMk89\njnYQKQxDFYZwg39+imAWAO5RmpS9e48TjuOIisr47dosd+iML8BioybSvdNO\nQ7Se2Sp8g79zZioLfAKQvk0xtD/jGcXqlkah4VbbHgvLUnEoixdY+yeILi1k\nIYK14uzdZRf3W2p/1uQilJ6SE1UmvzfeawvVzo/G956htHt62+jJgzq0iluZ\nQaxqezZ7YXUCUOnTIbgXL3YnsKZnrc+veWK/eUOTkAaAejmjIU7CHXzsrrgN\nf+OI\r\n=TesX\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCizmqK1+syGosa7P4Ff92z8+IXSAX7QK43+LsGYHMkRQIgd1fLMUCLC3A3iYgOL6vcluNEARcB6AVPwNPNk6dM9Is="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.10_1606310988172_0.9428135030930018"},"_hasShrinkwrap":false},"5.0.0-beta.11":{"name":"next-transpile-modules","version":"5.0.0-beta.11","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.11","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-dFY8dzrDf9xroY/in9R9Njts/jTzuvURbzqPTAF8grb6S3H0wuMJ2WoNMHIRY+3A1cJv1DFJUw+WTdy4U3CJrQ==","shasum":"f6e730dc8680366351057649d6eb72bc15aafa11","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.11.tgz","fileCount":4,"unpackedSize":22067,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvl0JCRA9TVsSAnZWagAAoVQP/Rv9o+CnH7MHa0qfLdqX\njNA2AtXT73HYwSrbDPYvS16dOZ/l7e6wK4SX/QqVViQBSzP4JYzwdOiSbikV\n/DZHDsampTANIKxovBG9YZ8WpEnjsnl+RrstS5GzZ0f/Ef+bZPahGCnAm3ij\n9/8Wv4TJjHSC21N/cECojMNh9ohrnRBpnlTsqcH56bGeAuV2RikpyxHaL5v4\nxtbF8XA/U+CrYLCNjcnyB8Qgb88eEU4u69OtF8LUhtlDET6OnSNWZkFwL433\n5dnQTzAX7t+dthbUVQVvVovzH3cdHJCGAlhwy+0vwY+UFdrX9xac/urBKGub\nONG/o5f4C+gblwa0AQ6ZwMjRVb9FJfr6EopKZHug5cUltH2zyxzQKIifAs28\ngcVgVm+/j04tvOgLoG7IbNd+lLs2RI77Tat+lpQ0mhM2shaxRwHY/Vha4i5l\nYRQ40vt0vGNpeLEhPV8429LkkcwH+eQnY/Fg937OK73Ke+YK9ZkTtZT1cQML\ndyr6AVzQV64S8K07JEZeSg6cbH7SumQT1Dzp9oh1maKftzuvG6mPiX+/mYTF\ns1vioJeILUVfN1sEOOSmRGFCq+mO6wL9fkgygzth3fFlWLCbcnMu/wkYHAIs\nBAE40RZm0IxYZXef4DbCG+7NTr/ihVBlJJ6NFc4Uy3FFYCddUcXDhGN2EQGt\ncbjg\r\n=hwnK\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD0Aqdx4OCBg1QpmBstf+LPQuB//+zFjRydvhykLl6VfwIhAPl1H9Ljc96i8AYmpiyIKOpiaHJMrwIjHQfA3UrF9Rll"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.11_1606311177395_0.9440393669222304"},"_hasShrinkwrap":false},"5.0.0-beta.12":{"name":"next-transpile-modules","version":"5.0.0-beta.12","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2","resolve":"^1.19.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.12","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-lRw8uLyKbLM5P7/oTHM3uavjnYxaqCkmrxpsURXjqHSX0nBXPSQyiUl7iiQTVVkTQSJlZA3xkxDkXDb2+el3MQ==","shasum":"59e1937d644af11220e5fc3b108017fb8d63037b","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.12.tgz","fileCount":4,"unpackedSize":22340,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvmtTCRA9TVsSAnZWagAAKC0QAIyqFmWemL8wlwj919sy\n+YvUKTHgK+XjxMzEAP4BA881NV9xrRoMYu9w1mK/tgtXGmScks/DXpcX6qro\nKJiQbvT8BgU0FDHYhMV4z777yz2IPy6DLc+Bh1vCy3MUDFG7DRUJwGql5Raj\n1wZSg71MoWuRgZXz1GGp5hgcvJmIMNGLN2fQQvM4pFkHZD/vX1o0OhcaMzRQ\nCGmjRuFMxKUxeICcSFZrRDl/seri4NKrGVATJo9+HvK4vK52Si/mKibHIshC\nYwy91+Kr4e0LUwud3LBndQu7clAqhDczIjgnbRTh1n/Ub1LHIgVGWx3R0rFi\nWAlKRfi3KYBb3wcxMf8gJg2UOVnRk1Xf7aMfFD4fGPAgAXOXgmSGjTQ7xwh0\nXVbThD/AuJUnrY1yafMBs1R2HJcrkaFzgQKwRBTP9WwiEMXkLBWXehIkinGs\nTVUdbZ33Y9IMVeb7bxK9Zhf5qnvMTIjquhA5/vibkDT3/TSROQQDg4N2GPB9\nyeIMH3+MS/DiWVRd9Fuce2mQPisNIHIHTImtrJGlxEpGEDKCiKoPhhRpCVqH\nhS3NFFj+x1OXhXGzESn24AWpAkqU+QduMdm8jTDKT+GQcs7mPwH1yh6Zc1s8\n6DsxuElMnr3au4gMkqRdSlQnAQfvnGojuaWHq0LVXAtETtuTXFObCLajBou/\nPyEq\r\n=8DLL\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGeVHkTIwWGC+b+h4EsKbEk9vbSwCOPlPxPdR3goAb3DAiBOpfGorJVSIn2BrFiUBOxvVKAi64tZxhsxPuVrbjBJIA=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.12_1606314835307_0.670058558933486"},"_hasShrinkwrap":false},"5.0.0-beta.13":{"name":"next-transpile-modules","version":"5.0.0-beta.13","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2","resolve":"^1.19.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.13","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-1KKy0J1Wy0D2YNRDqkxHWeOqgVqwfmBddp4Inf/AHyex1IqI9QvUfE35T3WAETud57qY+W+VYCpvCd6QeSMdJA==","shasum":"e16a08cdd95638fc76bd233cc0edb45f4b8a2dd4","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.13.tgz","fileCount":4,"unpackedSize":22028,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvmwwCRA9TVsSAnZWagAAdk4P/jG7ilg/9AkPinmkYgs9\n8RJl9lud/LnG6TZ4AwxpJSy219S9pwJ+ik1pZBvgVN0cXWf0TPiW89bCOH+j\nJAqySfESQc2utLAYMWUsjnIsgFkQykR5N3/cYCdJDcR3XtqZr3+Hk8ukhuTw\nZsmXDHyNrZiotXY/dbbpN5k8uhyEBGEbbQbwr/YB0YjXtdz+yQQvb8lPKTiR\njDnHl6Atax/m2gSpOh5afQs0YKM/045FtX+ROy6XbNFe6iB1MnSwQGjlpTyf\njws3eBD/2xCd1+Iyy4Mu2BvA3wQ0cpZ0p6M78qCh0j+9P/WcfUWHm0EP2Qnr\nTWH93S7qlvj3/GJ09NLWtEMvwfgv9FtScWBuO/w3/Ia0AEXzER9G46RULVql\n9WRV7KvbzUALgnNHnkQBoiW6WYJrQw4aJTkgv/BYyx3FtjCcy5+omonaOZ9X\nQnQh8bCKqaOLCw0RaJGnqX3OTqu2rbfj1lvZhYx9HOcsHIBoZ0JN20Pz0yo1\nzBlOA+WrlPN1u6Cu7sUDPgx0+tHKEUqixuReVwz0Vi7IInn8PFYWOaqakkbF\nzvWJxyHtRvnqeh4NUwpKkn4qsEkMvqsre5kXkCZVnUGqRSoahpkWs4I4a6RL\nw3IUe/E84WH2csfkhN+6ZpFqH4xuxDYTaLIKK4yTaKLg1GVoRC+HxXM8MSHT\nD0Xb\r\n=1n0y\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDEkiHnpsrOAAoUBrcqlL3AzO+e/kA2GSXGk9aXS20D9wIgdZtB9vXgYmHddbUgKm00V0RTjP6LR2ZO8RzwmdYnzv4="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.13_1606315055781_0.8558837881341221"},"_hasShrinkwrap":false},"5.0.0-beta.14":{"name":"next-transpile-modules","version":"5.0.0-beta.14","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"readme":"# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n![Dependencies](https://img.shields.io/david/martpie/next-transpile-modules)\n\nTranspile untranspiled modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version |\n| ----------------- | -------------- |\n| Next.js 9.5+ / 10 | 4.x            |\n| Next.js 9.2       | 3.x            |\n| Next.js 8 / 9     | 2.x            |\n| Next.js 6 / 7     | 1.x            |\n\nLatest version tested: **10.0.0**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (most of the time, you won't want that) (default to `false`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `unstable_webpack5` Boolean: Enable [Next.js Webpack 5 support](https://nextjs.org/blog/next-9-5#webpack-5-support-beta) (experimental) (default to `false`)\n\n**note:** unstable features may break in any patch or minor release without any warning, be careful!\n\nExample:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM();\n```\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another'], { unstable_webpack5: true });\n\nmodule.exports = withTM();\n```\n\n**note:** please declare `withTM` as your last plugin (the \"most nested\" one).\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/components']);\n\n// ...\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work with v5\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble making it work with Next.js 7\n\nNext.js 7 introduced Webpack 4 and Babel 7, [which changed a couple of things](https://github.com/zeit/next.js/issues/5393#issuecomment-458517433), especially for TypeScript and Flow plugins.\n\nIf you have a transpilation error when loading a page, check that your `babel.config.js` is up to date and valid, [you may have forgotten a preset](https://github.com/martpie/next-transpile-modules/issues/1#issuecomment-427749256) there.\n\n### I have trouble with transpilation and Flow/TypeScript\n\nIn your Next.js app, make sure you use a `babel.config.js` and not a `.babelrc` as Babel's configuration file (see explanation below).\n\n**Since Next.js 9, you probably don't need that file anymore**, as TypeScript is supported natively.\n\n### I have trouble with transpilation and Yarn workspaces\n\nIf you get a transpilation error when using Yarn workspaces, make sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and won't work as Yarn install dependencies in a parent directory).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nMake sure you are using a `babel.config.js` and not a `.babelrc`. The former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only.\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, in caps).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config) => {\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n","readmeFilename":"README.md","gitHead":"9bfd167ad3562c01fea2142a745ca54ce84666f2","_id":"next-transpile-modules@5.0.0-beta.14","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-1ynEnpz1VvTiLtgEcQgBY2sRl+p1thsXffVFIfuQR71JsmOFMAVDEaubQYoqVlfYKXwYazCsxFush4HBBzKCvA==","shasum":"951b1a5a28f4d8a9390ecda15083fcac6bb9faa1","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.14.tgz","fileCount":4,"unpackedSize":22011,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvmyhCRA9TVsSAnZWagAAk/MP/jKmLHkSxQDyAg+yn94y\nTZW6TVo0Zqfa6K0ge6vudjG73PzuDdebHcZyPGfb93DjszJt1uksHetVoX9X\nh5C5TxuJ1ZhyS98GTFRd/s5RzOOE2I8/1gFguPOkCsmSfhmJbFZLJ32YqIqr\nzZZdk0BfquMCnrNDdgK3cYkVyfDuUJhvgewDgtw1oWbt1ucttPJISb+I4dOx\nyM07vvb1RZcDfzz6vXZXkyYVef+ORSpga4h3QZf6f/RC4s+G3afla4bC6t9X\nKiCuRGBXnLBSS+853aESbHo+GAnRa3+j1QP5H8jcSYcB916hGRmIjosbHZbc\n3id7wiEla19xTLSGIw9OC8B+XZPt86RmnGxpe8m9Ss38lbQFYOYnBuoUL+pg\n7n1McDc3Mh/lnN29Q2e8k3iWNdfpdceDdIFoFEP01yx2d0YNAKpnY3nK3gNI\nZPpuDk6sjnTga0wbo2BhgvRQykC7A1EEzeImVkFO2QqHAZtOS4cUbl1RztPx\nq34w9dRYxl2EKSjfdY//qZa9VjLE506Ch0af6FPoHE5c7ZXfUa4NGqtTmnMv\n5W92pCbqosyK+8q3AtBvB0O4HzCE0kEkH5SbO3iDjfqVGMjvKNel6OKEy9Wm\n8VGcKmrtNkwnnwzECncgrklmAeC316FqUB14LVR7wC+NayC771rypy2RIguf\nzfzf\r\n=8qRN\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDz1lCC98bGFAI8m+nRIsUWbwizfokhYgxB64GddnYX9AiAkiPgXJInHhuX7o8deo8f29wCp4XXbWSwgK6x1wlb1uw=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.14_1606315168973_0.09411238528160748"},"_hasShrinkwrap":false},"5.0.0-beta.15":{"name":"next-transpile-modules","version":"5.0.0-beta.15","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"a0092c35860d5b72d5b2554bf0721f00caf6ecda","_id":"next-transpile-modules@5.0.0-beta.15","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-TZLWnBJt3sbhwnM9W5VMHc1JWF1gRLeoTl1/2Op/+aAsIyDm9RyC+xzjCfamwwCPofGf8tsR+ujoJbHkE7Oeaw==","shasum":"c76f9566a4e9b2f1dbc0def1c4a903999371a9e5","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0-beta.15.tgz","fileCount":4,"unpackedSize":22011,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfvm3sCRA9TVsSAnZWagAAX2UP/0qBQV/qsL5c5iZ2gkRU\nBU8wYnBJ3FThbAmik4CTc8+6GSOJ2kfoSaBdrRfBPiLLSe+o851ySIV3085U\nZSYClNl3Mxjnw9pbD3czniCamaMnj/b4+QH1IM866R8sfTViMgpSunvDVl2t\nnt/DNvgLXjyGOvaSVoiHEO2c/8wTGQAf/A2xq3Wr78VPfM3YEqTvvDhR0VI2\n/CLuRiZntXphBq0Rui7PA6ZKHpzt1tyGNqgOw9pFj8RC7whwmp2v93u+NsYW\nAxZycIO4WY1HW+EXdOKimb2CwuhkSNnspp71zH4W9AJz93oMMHNWuYTvk7cW\nkfRFBfd/Wh2vVaPa7kdKpOqQHHd2Xr/nW0VHtN5FmJZajGjbAFmK630l3KZJ\nbmJaL2jDRZ4yQX92KAE9nCboNMpKMasAjuvTrGpm3LXLtGpoqIE4wRijXsPx\nSC5wB1J0nRpOD/8hnylFyoW5xibBvjMlcxtmp8lUI4dZOrI6d8PPkLP6ikwx\n/KIKfZETGa7Yhrg8FoqS6jkQpfaJq7Oh0qM+mqUtF22dSq5glmffzp5qNJBJ\nSINRj/ovLRX2BiWFs8HxwtVpv/RjVIKcYMNZ4TZa4NRnbsIE250SmfU7x2+d\n/Pekh+Cmn+gujn0FEU4WQFohdmgxubFQj3d8dWJeuxJnJU+M/tbEsmj4RIEM\nNAZ5\r\n=mirq\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDcAhlzze5W2gyFLKWr5frjIWhOlGH7fzb92sLZOgLaUwIhANgK+lPpfvb3RhuosSNNORqjBO6XsN8+WD0K4cKmF8UC"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0-beta.15_1606315500350_0.41901275895918744"},"_hasShrinkwrap":false},"5.0.0":{"name":"next-transpile-modules","version":"5.0.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"cd37a7e02292ef5d307443d6d676fe6d0d570d91","_id":"next-transpile-modules@5.0.0","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-cImsh2YAq++sLpeOdUMRKwDFretSmJQyA/qToH84tBZXFe3L/bwTECd82M2K/dIklnvxmK1xbihDNksfMrnq/Q==","shasum":"a457295223d500454741de084170b920b68bfe63","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-5.0.0.tgz","fileCount":4,"unpackedSize":22253,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfv6F0CRA9TVsSAnZWagAAbYwP/3HZPjWU9+2TCT3hMLfT\nTsNc2wf54ICxwZSFV+SJalh4X0arP6Tlw7iSsT29XY/Pk+gC1bQ9nTZgvkmF\nayn18srgmSrGoH5sF/i7y2Mhh3t/Kj6EclXp+24AIy8rQynXT6ji4vNb2q35\nEcCq7pTF0sMBxkj/1KbKHcDdRaCEmHByy3kM+9PhqLfMw/1ujDcZQogxdKD/\n9eHLpIAuXPwCtTNCnQQCtajcWFh97CIIaGDSKV1HCA9dEFhK9Kf6mhEDcucE\nBvN5Z4dym5TVo47pj7WcNmmb0eI8U0D6CHn0sdm8IotL+1FEAY3NoUlvcimB\nxJL414XyFjKLN1jqyanFDznWMWfsYP/T78eaFD9tmkbJkxapfofIdklBhCa5\nf/kKBLlbkgGKMrOFn/LHm4WFtymcCMu5yNaCc1avQWn250x8C7FxZ8v8xl9h\nvGuNiR/NFsqBDc4ogcDjbQ7N20C5Wa4hUpez2sDueD1zehV00OnqmJNNU9jy\nxOH8TDmTAL7iBDtNmLEjfVJzJHuAuO3OTcYE3wy7oG2wwqwxHfnpLOej7Jvm\nbq/bkosK4CXcPUxjVGfVnjaWAOAIA3JGVKQbjk9fmGP5nrf/1qD9gMGtaCWN\n5tEUhIkC2gwLRH0lo9cgcPwL1Wqr7zcNdRffaydW1IH0VUQ3f5lYNg6a++tr\nSQWM\r\n=slD/\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIA3c4fPgz0STAc30/6WX5p21KqSPK/khh3RN2Dyo0lewAiAl5ToLRIJP8W/VE7tLTpIB7gfV4JAztxn4qOX9Oxr2eQ=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_5.0.0_1606394227911_0.9852801130998794"},"_hasShrinkwrap":false},"6.0.0":{"name":"next-transpile-modules","version":"6.0.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2","pkg-dir":"^5.0.0"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"59dc45103705e02947147d23b9a904de24652632","_id":"next-transpile-modules@6.0.0","_nodeVersion":"14.15.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-+Xdn4Upb8FeOXorzqVFyqww3kR9ML6S7y6Q3gFnoLdsqC5Jim3fwGNGTHENLOwedoKxcM6bCyRBuMYzyxru/wA==","shasum":"ba2d9c944de34a6e04c8834b6a06dbc4b28e4611","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-6.0.0.tgz","fileCount":4,"unpackedSize":23030,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfx2XOCRA9TVsSAnZWagAAIacP/3GBY/UPiB6p+N4KJ8NZ\nxwy5cAukRbOYni1tjSn1J7LmUKqaficylYGw5p2BFfJwYoOMMi11YQ5GhNIA\noGh46VeQvaMHgTZjEFQf644BUIkS0hx1ukrI5BWebUtjj7U93RjEP8LOUyTc\nZTFNu8DuVBnMZ0KGiTzxQFrO1wYJ9wEpPNd09yHmYZ58UfVyJtGltofW3Bbh\n8Es3JWC6Xoe0bE9jlhu+/o8MdIlhur31kHhd2qHL+reikYuKtI+8+yw9OsQ5\n4O2V0ZtFqNEGChrLWNncYE+IhUEs0KZCBjkk6pTTYET4NnDTr8cq7EYtpLPk\nZ5J2BXN/4ZKKi3k6e3jD1jqPlc2JPeM17sJMMW65uFYi0kZBmmqgo+6oGY9C\nPgY3o04vb77nvKG/gqBESeS4rTiCYTXt2gt56nyZ4ppK9SqaNORsQ1eXc9sH\noLohobPl0oFfyzSUfqPfPUj1+6EVONeHNzFoARv0kJMwGSbR09hNYm6CHCd+\nEZstcVIhua6zEjij/cqBapPrR+pqvGuGn6Nf3s7pJSAD+sqXvlf/7AaonxBk\nfqEZoZetflvBGjRaVYURdWTrA6HfTkeOEyAooDgbuCwHR4wTWGMmVvBhq2Pd\ny6bzgNaEvP2pEqkZSwo8lkKhyjtenLupVt2Ng+m8MMjmMKk2Xjro7hzpGtVg\nJ9xM\r\n=eu+j\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIF2FbPfYjWKxvtZktlztNLzMQLvZSFhgbTZuwz6BLTFzAiBnrtRkcUVnpqPazwAbYxU6R3X1+RtwFWbPh+P3WRooOQ=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_6.0.0_1606903245834_0.2985291296417214"},"_hasShrinkwrap":false},"6.1.0":{"name":"next-transpile-modules","version":"6.1.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.3.2","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.0","eslint":"^7.14.0","eslint-config-prettier":"^6.15.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.0.1","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.0","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"ecfe8757a3062106a668fa88bc2edde1ad95430f","_id":"next-transpile-modules@6.1.0","_nodeVersion":"14.15.1","_npmVersion":"6.14.8","dist":{"integrity":"sha512-IVjXHXnvr/n7liIe7SZcDbq3Gab4zltmKk7sC8zqn/L3TJt1V49W0OnUdtD/LRUdET3i34EfH/4p45SjgyQbNw==","shasum":"f5673044a9a955855733b15ab48ff12a05e5c5f4","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-6.1.0.tgz","fileCount":4,"unpackedSize":22460,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgEYoLCRA9TVsSAnZWagAAFIUQAJkyg7DgRALTIqgST0wZ\nhH0+zh3UczCOmohRDfrHJcP4eji/st8NQ7EeJSKErSqc4ffPMqJmqjKhxpm8\n0WewhXLIzpsLKLUfK8dQeVuVfosclhSYqKXU3uKGQSgEZiREIHgoFVCcYva7\nGKeNCFADz87dgL7+F/VV3Hde+jei+19yFSY6nBnClD6ASuXU9HSFXussuxX1\nwTsWwGc2elcCSjbQ2p/XKW/imWs9xwd2Xh2di8N4Hfj+QZflGhyx1Ho8rSQF\nSsrLc2YuVR49QpnBKvZ+8qe840RlH6ykRAobvOG4TTCaCuGGuQfamDtLyza9\nXrb/1AuqhcHkBJS/QlRbeAcRRjVxQ++JmKKn80BNA0ONGcKiFzJ2uv9T9y3S\ncrMGFUv48I51OMUwwVSviEesNpxiUEXD+y4FS3IUx6+m/I2mvWuXpZORqW0j\nln51aaKCyABhL6zEJrrTYFrkiE/A34ktV1cdvo/c/0BkI49Y6RzaQBA9uaik\nXwQMo30JOLF9J08FtmYE7SGI7ufKYXECo7AWDrGjd2EGXYkiSpJwlvfcVEmV\niM7Nm063uz5CUW3vecaIV/5tM4/SUx/hbaMJEHxUkV+c9rby1BL+5s1cOPOz\nqexd+erMpjrY5KK+XLoi7pJMzhSEUzXzo1hdKgqau2wZ+QTahH02OTTcYAED\nEWPB\r\n=1cMW\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGSIxuMeG4hhPUgv0e886Q056NYKQyB4l0aneGF5QVLiAiEA6ofUxTLHeSONgqkEVK7GRg9txUA4rrV52xcvkyCfNr4="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_6.1.0_1611762187195_0.2618681574747248"},"_hasShrinkwrap":false},"6.2.0":{"name":"next-transpile-modules","version":"6.2.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"1d271702350248ae5c011645fd24058f14c3108b","_id":"next-transpile-modules@6.2.0","_nodeVersion":"14.15.1","_npmVersion":"6.14.8","dist":{"integrity":"sha512-THMOWVuLqA16LsdU84pY+pKFfTHVykV1sJz2w6ANMZ7/yjfISHVHDxUnnGRP2XRK9Q/Wl9KBb5AK+spWv6j7yw==","shasum":"fcc55babdc2a2b2883589b4be4d9f0cc3922d2ff","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-6.2.0.tgz","fileCount":4,"unpackedSize":23086,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgG2N+CRA9TVsSAnZWagAAMUwP/17zybi1if2QjZ5rR40Y\n4N0FOICMfNN9t8D4EJy0dsAC8EeBTKeitFJ20SMWAn3aEk80b9mnQ4xn/bWg\nDfA9SgTDe5/YFRf72REEDBcW5DNW8LikUfDsebxSGH8Jw0UHBvV2LFx14cI8\nCJ5ALi9m8pCL9DbKqJeLGwJ1MKG60nshzNOavbsNijAiPvXGzNU1PQ3Q1MSq\nzyDePjazJdG7hka5ZAVfQdU8mk0otIhDN3zu/Bz4/EiSCP6QusoZum1uhFmn\n23kmBXf14zrmTGpifCH7R66mzCk65W2UtrCoiGldS0X1GFTMSMs1kk2AoPf7\nZMQgkClL+4A5ZNLaV7O/YgFSPooQalJcMzTgvFKc2sxxV7ulTQCoyWhoQGDY\nQT8MONUOiA9zRHHX1fTHYzih6tOppeuclzhek/axRyJuGtCRKnIKkxZk8ECa\nA/mM6iv+feBGfmDa0iijtGyVk07iQv5t1nJD+I6VAPiyQzfNmfKId53M7BmC\nVV2Fl/5Dntq7jynl2T+JJEynlSFSH6GHJdnVC8hQkVbpuM8/slgaUP6AsJZI\nfXyqXIKIVj6b4FX5GLt1R85f/kbYYs+mFOb5FJzyDUnTWyfZGalygUA4r1tO\nHedEZ3zuFVhi9LftKlqLkw26J/v1qgibl119UegKV0xb6N7HmfE0uDtEVMtK\ny3e7\r\n=PX9Y\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCR5GgaPMTY2mK83qXvuaPC6rG9q/cxBWf+rA4vHnkQ6AIhALvXAB+MOZ7/NFhMtWVEJtnamNYP1G6/YBFBGLAPaI6x"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_6.2.0_1612407678378_0.02318247943438756"},"_hasShrinkwrap":false},"6.3.0":{"name":"next-transpile-modules","version":"6.3.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-worskpaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-worskpaces && npm run test:prepare:webpack-5 && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"2d935beb70f8420ca42dd0d7bb2ca6755ff8d38c","_id":"next-transpile-modules@6.3.0","_nodeVersion":"15.8.0","_npmVersion":"7.5.0","dist":{"integrity":"sha512-ehR2RkJdNrJTvJ/cRCT4/qpcmU/FB/61RcKV4amAgTMSMQD1tmkle0ji38zCUhtffs7H2UfCioDjJxd3zthitg==","shasum":"291ccb792cda73322a434590893e9965ed65a533","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-6.3.0.tgz","fileCount":4,"unpackedSize":23582,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgIVB/CRA9TVsSAnZWagAAOoIQAIHCIsHI8a2otzOgq3po\nBYb9SRh3Oe4a7VLCmSXjG2HcbVpLhm+ETkFMcBPR0KDFfUxEcPS8QhC+6Tz2\nrxXvlFJ3h8tHC2FHMwf+LHFjDuGkStKhrSSG11t+C16efOVFUGG8pcteli0L\ns0n62FiZe+LNUUJymKxhuZtt+U9Nv+r8vfxEtO0OgLa+EV4qW77Uc5jpq2Mo\nm8/sdsWBWz9Wt8wR4Ltl+ih0Y16khmaN6I1MpiHskOaUrEkS63Nx8FgxA11K\noQMTMAFWZ9mIFbvTSn0SbA1KCIEA+pT/iiJTu9NqUFs5MGLxWE9Vlub96rQ1\nIljGGu5otkleZuXrHTqLaQCkVj4AcymbW/mN3Cop1nHvHHzSk2heyFlJmQTN\nl1JKYU0NHlkPlW77up0MDAT6EwBVf0ZlBJTlGvbT6pTLOT2s2tfEW7q6pb+U\n5Cj4jxWAb0C6P0dumte2a1AjPNU/ezX8lbFC7jX+VPCtage2UxNveix/euoN\nIRVM+LBHT4nNps27VQC7ecBLkoo7VxH8vrs+gbUV3AWvhzsqiqY4WPi5Y0mj\nGyWxv2kYbAh8mF3xUbRnpBmqod1ZuMKGwh8Sx+4zTgYiwUvIMXLTqsanBKVu\nUyuPlUltIPl5RJj5HdK0tdNsSn5PydkBix1Bcr8fBz4oEeaHRqxn2EOwiEtD\n8VC2\r\n=2rdK\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCQnek8D/wehwnlrD6EfnWL8SnppmTGpb3PozBHOGt/+gIhANwn/8njy4fRzCu/1Hboq9L2bW5XX3V+I8WLHNDxW+/e"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_6.3.0_1612796030730_0.9697672453667863"},"_hasShrinkwrap":false},"6.4.0":{"name":"next-transpile-modules","version":"6.4.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"pretest":"node --trace-uncaught src/__tests__/setup.js","quickie":"node --trace-uncaught src/__tests__/setup.js && npm run dev --prefix src/__tests__/__apps__/npm-basic","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:webpack-5-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-5-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-5 && npm run test:prepare:webpack-5-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"fa1fdfe60cdb8e5b3945bf361c47c43d1237886c","_id":"next-transpile-modules@6.4.0","_nodeVersion":"14.15.5","_npmVersion":"6.14.11","dist":{"integrity":"sha512-Wg9xhHJGZZwAnq4nh0UXkevmX4dOUGtNmCiQzo5LhWqEJV0ToE0/OJjvOde+Qigb5gSkjGsaJLbO+Vn3SyAStQ==","shasum":"fe52ee0ddae9c55b4d0f42cc6d1cb7b8878c619d","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-6.4.0.tgz","fileCount":4,"unpackedSize":25774,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgZOi/CRA9TVsSAnZWagAA+4AP/RKY6FJXsXShN4OcuQhe\ngoZD3LXhyfktBavi0YaPm4CK6LQxbLPLfZ1LOlnxxOCzo03uEEce8UBhrFDv\ndExGSarUTEa7X6daD4QKtDuDUsxBxOhcg/KpLRuJ0mI0PRrYjCzQ61v/HPc2\nLZRpcKlmr1+lGW+gMKNsILHAtoHINkYmuDwonpOf9Q10RqY385qVQE1VUug+\nZV6koGJf6+oNZGgAgdfCkdXyQ6kXoddJp/1Y2wmeYRJB0WI1tn7DkKRiqgQk\ncQMS3KQOsVt1az1/Hxq3pnWtgvXHbvMZCh1Rv4qC3nZwWS0HRzYUhva0rZBj\njy4JDrsHkgDxhqsgVufLkwc9mZ1kDqkA78f1GBS/c3yZICavI/YiWiB33N11\nBDIauqstbqbtOvpKkdt/in+435jfuuF7xxfHX8TQY8qPXTiGyWSQ62ZpeQv8\nElHiKlcBPu3NvsZn2j4TSgdsSlY97aBkC3XCMAJ7BTiRaP3vOIWTMKqsNTFB\nr1vTjbQhx6EBW6m0ziqYtzDlIuBOU55Evic6V23ug4ihW3a7PolYSE/8vTNZ\nFTgBbljuBYm1Hove6R5Rt6Kp8zo7h5ksG+EM/4+Rq1lracFqhIgXKzJjXLQq\nRDnBzwtiiMaSsaXtmsWRmsi837yKABBN+zNGibq44fneSKeYGcQJwZcrj5jX\nvlxa\r\n=zf1S\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDE/2adj4miOUEYU5BS2CYvbmr5a7VQZcF590Aqtsj6OAiEAg5t4Bz/uMpvIqq9CB8kaRTYKEpntUz9N7w/+1EZ6xng="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_6.4.0_1617225919417_0.050209459542173596"},"_hasShrinkwrap":false},"6.4.1":{"name":"next-transpile-modules","version":"6.4.1","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-5/app run build","test:prepare:webpack-5-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-5-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-5 && npm run test:prepare:webpack-5-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","webpack":"^4.44.0"},"gitHead":"99dc986072e1213cc551d94ca041c41beff25b20","_id":"next-transpile-modules@6.4.1","_nodeVersion":"14.16.1","_npmVersion":"7.9.0","dist":{"integrity":"sha512-trUMkm+bkjMci7mXSOQkF3apEY18K6YuaeG4mkLwiQtDdsmdVXzopNyZGc2nJq8OwHYDgJr1QlsBQuQb/2vXlw==","shasum":"471ceff06439d1681447c43ef8856268f8596186","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-6.4.1.tgz","fileCount":4,"unpackedSize":25912,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJghnK0CRA9TVsSAnZWagAAiKcP/1B9rpu7tx8kDVSfp+Xd\nNB4fM8BxRCLbQRtddCSKIFNfHikxv0dzOYI3+hin/bO5ewvap/AIXnXZkCIm\nA/j4FQWUyfS5GupNPPYldcBr0BbjeBOhJbqB90x1pP5mUjTAXsRWbA3caWGA\nsdAce66ttJ2KQmsfHzCYOhyMzFT5DS486k78pp5TeFLSnMsIhfdaqJvBqmwb\njTp52QAeHAA7IgEOA5Rh8aghD0WH5Fnp9WFo6U+ZOaApDzu7j3tZcf0Ye8Hw\nDBssBkzSRc8suchzevK1l1hMIg9GRipX/xuRqEfHaWjEo2EefnX5KAydtSlu\no1CsSXzjfdjhFLUAF40dRzij0KE8E6U3TSVe3DvQYiItz0bumoyadc2ySriO\nv/FO/NgCIQJjMtb6DCzS8dKu6zBUWVoyoMCI0o5OwHpoJGXJho2AcKA/GXjq\nBM5aMVQ9ChhHQXVZ+/QnDmd3EZqjx7IRl6OzzpJ6085KpDA8r+H2gVfY+gRe\nlrbdkjD4/CT7SljFfa0lECGwi+hy8azlZJXdHA7Dt5hZNfeE6kO+MYDmE4As\n41WiZr3PZja507UqCDt5X3qnmFHXS8dwq4qEUDdnhKH0x9HSGazM166CDwDj\nFDhz6yl/TRNfd1pN2Mcy5Rmtx+iV9AGqdIUnx8dBK9+4MS1/MyzAzPXClaCm\nYbfP\r\n=cSap\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCpc40i8Pbc8wAZBbEx7i0AV0ULNSuXYyXRIzz1EDLw9QIgRwmcrw7492VjIqucRbnE10KU7TV3lv7Udd6aiVWYOTM="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_6.4.1_1619423923439_0.606937575172211"},"_hasShrinkwrap":false},"7.0.0":{"name":"next-transpile-modules","version":"7.0.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-5":"yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test:prepare:webpack-5-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-4-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-5 && npm run test:prepare:webpack-5-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"gitHead":"66482b0d77141adc2f305916d630af22045ab09e","_id":"next-transpile-modules@7.0.0","_nodeVersion":"14.16.1","_npmVersion":"7.9.0","dist":{"integrity":"sha512-HgVczU5ajXKvE7HO3ZLmBmxXj79aq8jSZNYpCttim+MZ+b0GIsdk7AV2w7Ax/tIM1/dJA+vV/6loXCRYlbsGGA==","shasum":"5a48988cede89bc5920defb15378093d0d8562eb","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-7.0.0.tgz","fileCount":5,"unpackedSize":26593,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgibYFCRA9TVsSAnZWagAANoUP/iGosYifrfjMFbgNG046\nB/4u47SPiA6jBit+clGUnk8453eaN5i8JhjhoTo66geQDgO5yKH9YTMnyOVW\nQT5dY5Nmt9bF+grWisN9Jjzq6ktgiWI0H+BGtR48McGWCgMIwe5/bu+XZyU7\nr0bGZ121Of8ovaQEICfqYeOtiE1Ewy/0f3C7Ofkw+6gm5vBleEhi5hPpe0gM\nF0NdBOcvQMWKa/rFatvOCwDn1wyOS7xrMd3btXHJxxhuve2F5S5c/lCA3Zct\n8vvA89BmbzJ6kx7fqi4GcOIuedfKyMIja0huRgvr4FC2kNFa/MkiBMzxx2vY\ncs/liUhC9x+ZuurUIhdFN733DJtY/ZZxiZotr3ajBUdjyAb0ReePnYQuI6xV\nuenuhTNiK3QxSn5WzAWlUwDUzqohFh48vX45HtgbceZea8fu5IKt8ufkXRwH\nfA9tu32vkYRbCKVUOzbe5360Hyy9J+KaGtDTBfPlY1KClNNOmbjEwjZKQf+U\nOY1GFyeloZXWvhxVZsdIPWgHPOzK73U47CgMcUYIahcPUY8IY/fhW66mCzpZ\nwD+mCtGkB5DUfzrJksoh5afSKU15lLZlALVeTWlnloOaE0o4J4k9uqNt+yAu\naHO9tneKhMrWXC1nFWRxZVTiHbPRNGpR0mlLckrXp4ukhTjvJvtlHisXAv+t\nDmr2\r\n=sMkm\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEqvqAEHgp2QEE3QItam/4c86sXgHscw6o1NgqoLAjF3AiEAwxO6r2zfnIoHAcX7K1vvr9L6TEBzl+uCtJ323ZWmaVU="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_7.0.0_1619637764944_0.9252398095415875"},"_hasShrinkwrap":false},"7.1.0":{"name":"next-transpile-modules","version":"7.1.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-4":"yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test:prepare:webpack-4-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-4-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-4 && npm run test:prepare:webpack-4-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"gitHead":"7c1039bbcc5cc316c53c7222cbc38bde5b61ce70","_id":"next-transpile-modules@7.1.0","_nodeVersion":"14.16.1","_npmVersion":"7.11.1","dist":{"integrity":"sha512-om3XfamWztW0zAdirCoyjcMNiQg3zesUlCSWh1FS6t1LgqUT+AjH1Zc5OpLMZtj7qsbwmLIOeFN72qrnhbpefw==","shasum":"f4cae86913c9f28e66926d19e1c672a33d28f653","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-7.1.0.tgz","fileCount":5,"unpackedSize":29036,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgotAZCRA9TVsSAnZWagAAe10P/1JW6zICldbIYNPktNiy\nC2YIVvFlxRbex5KljjRSHdraFMN5Dd003QgmX3eYU3PoMqCyOMn9D50PryX2\nfcTojxWarXEPSka4iJrnpawyV7skynyP9/2TU34UGYOMu9Gy3BijRQji5un9\n+oU92u2DjtBVNElO+WBhI3kpMJHRooq9WSNztQDQna7epcztvXvGR9Z7/EVY\nWVj27LfsnsVQKDx8Uo3UxsIIzRMZvHN7zTMZc5ZlOFXtsJmbMR+3ld4xdFFC\nzI89JL2DSnPxFbLLI/acE+Wj1FgL9wG6BqWO6YR0Og5Sd06/Ktd/IXilfQdj\nIoMirbJofw07b+TaHmdEoPVIONIjsyYZGLYgwPEiPaxIgaBYkupr1e+tOVa0\nhxK48VfiklL070yYHF88bqLvaH9ff0quCIFN2hO5kfn4iasBLHgT/8aSqTOP\nnvpMVAwOeA1W6AxOnbNdDY9mHeHsjCxzL7RKfOCbiYlgipa127f1WsW8BbUF\n7IbH/0I6X8FtWL8n+IP0fyAUUy+b26dLoMqgMMVtME75Ui9jxyYDYfMLGrCP\n3zSFABO/i5e7UL2pQ/Ue9MDn1pSitFlB1rcZ2ZrYUCcWmBwvbE6Ay916T0YL\nE0slVNZJUj5BRcr6gYZ941ltdKxxwqKVIiFMi12VqhYmGQHS+Z8mLlPZzsbR\nNpsp\r\n=rLZf\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAqnm9RrQ22MvLLpH+O/Day7E0XilKaTeQ6HL4c/aRXLAiAkAYfDtIXgQfnXSGWMGx1kfdW6aCoETfr/H8wjBdtSqA=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_7.1.0_1621282840708_0.28193553338172284"},"_hasShrinkwrap":false},"7.1.1":{"name":"next-transpile-modules","version":"7.1.1","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-4":"yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test:prepare:webpack-4-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-4-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-4 && npm run test:prepare:webpack-4-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"gitHead":"7d6cbca68023a875f4c75e83375793cd5bb6b5b0","_id":"next-transpile-modules@7.1.1","_nodeVersion":"14.16.1","_npmVersion":"7.11.1","dist":{"integrity":"sha512-5RMqiNAWkulK8/2Lx6MrPKlurro8zENbzB5sw47QKUyjzjHJ5+RJuBC1oNHK3PypISSAm/j31Vv5EULy+GTE6Q==","shasum":"6a07908662ec73788eae349e3da0d82e6e1fabee","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-7.1.1.tgz","fileCount":5,"unpackedSize":27789,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgo490CRA9TVsSAnZWagAAdgYQAIv1hOXFZLQSlyKsBnI7\nIBkFndU6rYU32UvX5zPEjOd9iHsaO1v+pgxp8VXRsJU23Bs/3WaHxURQa4Qp\nsjo4weMjJd53enqW+XxlkeNz//kO7WDl8AEtFUz5OWdw/gdUtLV/8ayhe/Gn\n4DyBzFTGvAc6POgCyhl4J7pU1MNXauy7TBrAHgYfBOPUIjZhjIrVzvjldIwB\nsz7CWA4qsa5rDoBfYuBg3gQLLC476iPzIssYjhoRj+5lRjjPP3MxA36nrEW+\nZsqmPT7yHnjuQZEy3ft2NYTDNY/uPFOzrdsTFASTDpvPSK/Jr0MZWzgk+7N4\n7MVD0kFYHofZEZhvOF52ffhh+uoifJkdURyJAszOVWXEH8SGfE/d5oBS2dR0\nYt1R+LMOIl4H9/ab1i7g/CLFQbGOFF3CE71R1B4FXthwej1v+OHsxUBIFX69\ndK/FJrVwNNUm/cPMQqiZu/2tAbv2HJoH8qozBZ3LIxZP59Zhw9RTHbHzcjPF\nPaWbWUNzHCBbw4PH/J8hxSWDXQCWkHthDQDhHwMSZAqV4/Mx3NfOQ67IWo3C\nMBEr0tcSUzMaLRZq7c/xQVNWa7N1kSHj6a9H6c2vnrp5airCQz7iQLb2M0NZ\nxjdWCroMVKcSM3ue1f+tIrh76x8hxoMQ+KScz6Qf/wcrHEoLjbB7hM8kBNi7\nZ2Eq\r\n=Ytbb\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBGPOGFrA9ZYyLcnDQe5+SD3j77qH78/qimikcvGUhDUAiAskr7fgbe0H1ebLhxpywqm9vZteZdu3yoAgaIZjOkKog=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_7.1.1_1621331828342_0.8709154472749552"},"_hasShrinkwrap":false},"7.1.2":{"name":"next-transpile-modules","version":"7.1.2","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-4":"yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test:prepare:webpack-4-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-4-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-4 && npm run test:prepare:webpack-4-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"gitHead":"d1f694bde8c893d6d21a60d9c43c3c8966ba2875","_id":"next-transpile-modules@7.1.2","_nodeVersion":"16.0.0","_npmVersion":"7.10.0","dist":{"integrity":"sha512-uKizsjRNB++vIcIyJ6zlf+SagsYsnrXecRtKl8mdlCbEl1Q1KlaV0Arb/dopWWWR29dnOlvCKiaCxODW79k1xg==","shasum":"a58add6f9a6910e0c4ef8c1ecafd4a5f33959186","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-7.1.2.tgz","fileCount":5,"unpackedSize":28090,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgpR9+CRA9TVsSAnZWagAA+f4P/AglA609T1hXkH156Pdu\n/UhRSRK9Z6uzxGe0N1eDgokDZKwHlrhv9unCbNqzclYuLuYSUtr98y61rBA5\nTQ7g6ptoN/y+e8o6WqV3D5CDfy4WoeKpxphKu5o4R8tTvyHiIgpkmVNq07YY\nT9YQHdmLoBnd7hgqwP+1PPMAMhykuFkHvx31dqpNsE/EJyzlEfPE8f6qNh7Q\njc91sPalx3jDxl9vmuoYupxnrB1LKMKJV7v7hX8RB1QtVJQP37qHuooezmHA\nsYbwbpecpRXKEmgxkCkRYTFVBWc1tZgHLVrTsxGinPtr28XaGg6Afyvj95pb\nrl8jFypGdukdde7Mx0RYpQueIpq97nfh6WX75ESNdQqFj5LWZNP1295NYH+I\nwAPxaUtSKjIOIXu4fxaFap+fG3C3pKyskjCinSUbPz7yEDxzRat8gqzb2zkR\nFGoPIbEDjTWzyd8B7m+/SaMffYYdqzATl9zFfJmPnwOS6NUXXFKAwGudE3x/\nCQCqGp0T26lHcucJuBRRZQ5rmNhEK1DxGJhvwotggnACYCu7iAk8SwWpr+3D\nkTQGDsoLnpxU6o4FGt+tHSZQQZ3TuVUSbVql0b0d3QuFLLyhkqY5mmL5hI0A\nCD9fE5EA+4iIp1qPYp0k3RYyn/YmjTFyg6ab6Ouq1VOouZ4EDEAUP9ZscJdq\nChlT\r\n=U1LR\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDVi7v0GTvrcUyZTFg9nYnpA1FHiXMAQURZ0cWSYSNHpgIgONx6NIjqMU1mbICj4eBp0wcESqX8gNco8l+7DjrwCdM="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_7.1.2_1621434237878_0.06030464378623712"},"_hasShrinkwrap":false},"7.2.0":{"name":"next-transpile-modules","version":"7.2.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run dev","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-4":"yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test:prepare:webpack-4-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-4-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-4 && npm run test:prepare:webpack-4-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"gitHead":"2d9de2c1b1b71f17334dc9cda287e3a45d3e63ad","_id":"next-transpile-modules@7.2.0","_nodeVersion":"14.16.1","_npmVersion":"7.11.1","dist":{"integrity":"sha512-7kd3/MkqKWz4fZvrIugNQAUo2RUpA8tYY6dwCMgIoFkbo+i3Gm5h0gTieWfUj7eAV/EpO/pqp6DQy2AJqrRdqQ==","shasum":"5100cbcd7740a038d4d5f35791a5b00b5ac80421","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-7.2.0.tgz","fileCount":5,"unpackedSize":29627,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgp6eiCRA9TVsSAnZWagAABNUP/3cv7ja/bxRPYqj2gnuc\nhTWawc+25biVVICY6y1sK6sGwvzbjp8V6kUvQP0OH2uvCPBVdqxY3RxJrS7s\nHNAUorXmiO+Ff7eey/RFreoxPxKc2K6+2930s7v0isWh67WN0AIGS/b78KLs\no0655IRPH2H/YH6z3c7I6oj11d/3NE4UI64VhIRbDgvviMCrTE56WeTz7koJ\nsCOdkXthLjIiIvHVrIPn0Kt3tFlFa8RTkGk8+9v9YBKKXx3x+pxAcgvQ1Q9l\nR5KxZHhdVuTTc/QvsCnudbbJMyCoQblhPhkaG7JiIIvx+yfn4mp0UjgnknRj\nK776SRtYrLiyBsXJIMCEdedjOkf5glCTY2jt/eP1gEmUAi5gM0yugQt5SeUk\niEQ2kP8mQFk+2x05oZ2yDgEggJ+fh/P9QVywoRfhFGHzL100607pz5LybBwy\nA1Jj2rNlz510VYapxsS++zT++IDX0ZwQ4Y9ZJ0iPR5vSsUhyYhIIP2JEXnaF\n0ZEDXZS4BlzGRE0eDKn4WMVuoH2TsQDXq/cNGMInWj/nmLC0f9WRp9YUBAZQ\nGbbwRahB5ufGp5io76VpUwAFuPvzJOQwOHOUTFG9Aq9g+sWlgodG0vLWOa2J\nXmVKetqCkv2zpAgPsxqn+1RyywlDwcBWSY6ziIuOapt3QFhUC20+79sly0Fz\npIc6\r\n=C3ik\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDDu8+99JLm7XVJM3SeJ1yvNYzEQ+qtcfFzIFfVwvaJ0AiAudRV86On2XJi5yDOXZJ01Sq9sV1Ilvdw7L3HUoUl9kw=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_7.2.0_1621600162175_0.15773083094419005"},"_hasShrinkwrap":false},"7.3.0":{"name":"next-transpile-modules","version":"7.3.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run dev","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-4":"yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test:prepare:webpack-4-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-4-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-4 && npm run test:prepare:webpack-4-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"gitHead":"c6605eb9d1988effb4f80356c7573c7c8ed4201a","_id":"next-transpile-modules@7.3.0","_nodeVersion":"14.16.1","_npmVersion":"7.11.1","dist":{"integrity":"sha512-1iIiXEL/tyqd9LS3ge8nhPLgYByaFxLSBqbaQZZBedTgFVVnULrcdGDBVqWzivkcxDIqBpdeou+FKqo87IUyVw==","shasum":"088bfc2baeff7624991d4b510558c7a9d4a82d73","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-7.3.0.tgz","fileCount":5,"unpackedSize":29653,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgwT65CRA9TVsSAnZWagAAwusP/R5v2efZgMGILXL94+S6\nXhiN+2reiutV9Plir1jvM4uBGdI9p+YqGemAd8OxI8rsAI6RMmmZDISbQnZe\nLt6aYBrpJkAZdL0BGNslyOYL6vKi94KXEXzOsqcTzb3HQ2WJPQ3mjwCY67UY\n+RFlwRNouyriiIO28wNqH2nV0XXwvk8zRivLo6rHAFVpKWP70VZPVXIqivpl\ngvs1frwvwzoBtIrd38/CWATHy5EQVKikrUkA4E4BCpTfI0wTQPuqK/BLjJkp\nu7t/04yFU0So6rDMX4QkafxflrUcRTKjPpnZJNZyKzR8x0A8X4n+gXDIny+W\nkgkL6ZegVlmeNiynwGbd0pLbMBIB8OhsOgRUhm79FTkCpx+JpfWbVI7aSHi4\noKYU6Cl8ynvttNVztkyZohbuKcrrdzxq9mLX9X5ij5XFuYTOJL4H6wXkyqIW\nu7aBADQujxhnj2pirfpq0LPjGoyl4j5Q0tvP9WJWscP35Ar4E9xyeo/yV+/3\nPVkzOvg92DZNCxNZRRwsFHdw2uuk6fPBUD4tQKACIOydskOVGfxrgdGIHFLM\nww9cx90qNCqLlb6PSVL+1lefopPZD904pJfSg4X3xzo2/ga/svLpL/njnhpi\n4FySn+vTNmfHuU54akuhovFOh/YmJDFcbDCh2SzJ5MuY39i1tDgpiPjbEctP\n4hcs\r\n=rMAB\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCBjyImayqThworjDn4H80N93O7tNnGkQODIBR4EzywFAIhANkaUZboTgoYLK3MX9zcqvAOlycsI6KNzwhsP3qmfhg/"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_7.3.0_1623277241422_0.5545360537727888"},"_hasShrinkwrap":false},"8.0.0":{"name":"next-transpile-modules","version":"8.0.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run dev","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:webpack-4":"yarn --cwd src/__tests__/__apps__/webpack-4/app run build","test:prepare:webpack-4-symlinks":"yarn --cwd src/__tests__/__apps__/webpack-4-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:webpack-4 && npm run test:prepare:webpack-4-symlinks && npm run test:prepare:pnpm"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"gitHead":"6692f2f60507281ed4561d9a875b064bc5924a99","_id":"next-transpile-modules@8.0.0","_nodeVersion":"14.16.1","_npmVersion":"6.14.13","dist":{"integrity":"sha512-Q2f2yB0zMJ8KJbIYAeZoIxG6cSfVk813zr6B5HzsLMBVcJ3FaF8lKr7WG66n0KlHCwjLSmf/6EkgI6QQVWHrDw==","shasum":"56375cdc25ae5d23a834195f277fc2737b26cb97","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-8.0.0.tgz","fileCount":5,"unpackedSize":29658,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgyPfdCRA9TVsSAnZWagAAcDIP/jad7MxHH+gjIidRZKIw\n57JLgHROH4RYciZnf+AqrKBynGLYtBTx0ydjKw56KteK9SR1uOfEnB7Zwy+y\nRzeuFiHRlpuoH4UebR/CMRldVdNMju6VZJVElxexYOxDpqjU+775zLX578Ou\nS5wtcQhNsCJHjJTbcUDZ/E1MMhqW0AvGgK84rRBHCG5QAxkfDJeplCjnj+9i\nkv5rPzsX/cOCN4irBpVBtRjP6FH9MGI+4Rp3Xf603gsjt/6fzcdrGtMYXGPx\nuasxPRQ2I/3K0bwRVz6Haa1xevmi/AEbFQjPVKgGPVoxZGl368WMt4KjRZQo\nFHPt8ld4xIVmDCh+IWTu3YEVcB4eir2lPrLhsvg0GgLk7DdFG/oFluv7vY8a\nDLRGjNGihiwVPHgjnNFj6ogDgAtQTWT6qbypIzsKZOtpEqob+GtJTaHGmYwG\nxDkWATNu/XpodfNftwHaQvaHLu+5swxkdrK4uL8tUX5K8YJK6tRBT8kfX7Rl\nELU+zENARyOb5ODiS0JbzHZkWgRivYwJS3aSYyRnypkvpDizV35z+Rei6ZkC\nsBqA5XYRLaDOSWd2LilAC9xI64wlAH01UPfwhj4YFKwNQ63qb8oL6ysYkM2s\nX/rvX5Wm4vzhfnTZ3ldQjuwNcKUBoRS5WKTVd1mOo/X6V4YRjOtZ4Lg9YsiO\n06XN\r\n=cH8v\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCxo3Zv4TMtZcUel1SZ5fqwVJ9BKLgEQ7QWatS5W7Z+rwIgEU6Xo+q0IzsLrR2w0HYKpgMdcXWUHCjRmPqcmo/GxV4="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_8.0.0_1623783388998_0.440223211749712"},"_hasShrinkwrap":false},"9.0.0":{"name":"next-transpile-modules","version":"9.0.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules (supports TypeScript)","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/swc/app run dev","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare:swc":"yarn --cwd src/__tests__/__apps__/swc/app run build","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:pnpm && npm run test:prepare:swc"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.7.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"4.4.1","eslint":"^7.18.0","eslint-config-prettier":"^7.2.0","eslint-config-semistandard":"^15.0.1","eslint-plugin-import":"^2.22.1","eslint-plugin-jest":"^24.1.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^4.2.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^9.1.0","jest":"^26.6.3","jest-environment-node":"^26.6.2","jest-environment-puppeteer":"^4.4.0","jest-puppeteer":"^4.4.0","prettier":"^2.2.1","prettier-eslint":"^12.0.0","puppeteer":"^5.5.0","rewire":"^4.0.1","typescript":"^3.9.7","webpack":"^4.44.0"},"types":"./src/next-transpile-modules.d.ts","gitHead":"05437e6467893538c5f527555c65c686e411603d","_id":"next-transpile-modules@9.0.0","_nodeVersion":"16.11.1","_npmVersion":"8.0.0","dist":{"integrity":"sha512-VCNFOazIAnXn1hvgYYSTYMnoWgKgwlYh4lm1pKbSfiB3kj5ZYLcKVhfh3jkPOg1cnd9DP+pte9yCUocdPEUBTQ==","shasum":"133b1742af082e61cc76b02a0f12ffd40ce2bf90","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-9.0.0.tgz","fileCount":5,"unpackedSize":26128,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh20eaCRA9TVsSAnZWagAAaokP/0SBz15AO2In3kDVYDwM\ngKGOf9oNB/voY7UCoJPCIrPeo8ayS4G42aGQkXo0Gz6g2t/p0KxSAwCZReeF\nfY5fY35XB90Npp2lKRgA6HRR779ncVcylGaXRVApC7fAzUJBlrET69Zf7EE/\nb77QM9ABzlXIEfo64mSoAhfHGHLrrI5CeWE6+oQ58mISJ29OBKZNUoYZE74i\njD7wl68Sl2pVUIwe5ErEOuWUq8PfY7079xhNva3N1PwXp7HI8IKVi48vAEze\nAk3MS9UHTqG0Lbwu33+DMKO8uNzpZ8HbUqZdHQulQ6FJvQ6M/v/zwmLHnaQ1\nkJNXEPCMVRs2gFoCNFfWu24dnJtMHNsFo5/UKdu9z+AnQVEmk26KUI3notgN\nhGjWcenLNidKVkBn5qXGzBxr3eZ1G1b10b9GFRTfgK7v3PGxEAsYKM78oVPW\nj1A71O+JedLL2/8O65r2Wqh/8oLmxh2EMdPf16K7Mqkge0M0jn2dYgev2JXt\nrlqtGuZ12PEJWbANy+Za1UJtyI2X2eItaM4KHN/hY4sMHtMdFrSEj5lYsew6\nnd57HMrZ4lwEesuZTfpM0Niro0YqMpCY3P67f0QmXmTgagVv11ijDUo1EATv\noSe5y2svK9LKTdjN8jso28jm5tT3wDnkLrz3+bUsxeDfaFbEXytlfHesIaOC\nmltz\r\n=1vjT\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC5XVCbiovfwCIdx1ZkXgOwVP0Gc7IeikVhdpFSrfuWDwIhANBi8QJrXzNUYKe0KwAGBXvmrMAHx/Owjnwf5rioRH3s"}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_9.0.0_1635326760750_0.28577837980617327"},"_hasShrinkwrap":false},"9.1.0":{"name":"next-transpile-modules","version":"9.1.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/swc/app run dev","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare:swc":"yarn --cwd src/__tests__/__apps__/swc/app run build","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:pnpm && npm run test:prepare:swc"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.10.0","escalade":"^3.1.1"},"devDependencies":{"@types/jest-environment-puppeteer":"5.0.2","eslint":"^8.25.0","eslint-config-prettier":"^8.5.0","eslint-config-semistandard":"^17.0.0","eslint-plugin-import":"^2.26.0","eslint-plugin-jest":"^27.1.1","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^6.0.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^10.1.0","jest":"^29.1.2","jest-environment-node":"^29.1.2","jest-environment-puppeteer":"^6.1.1","jest-puppeteer":"^6.1.1","prettier":"^2.7.1","prettier-eslint":"^15.0.1","puppeteer":"18.2.1","rewire":"^6.0.0","typescript":"^4.8.4","webpack":"^5.74.0"},"types":"./src/next-transpile-modules.d.ts","gitHead":"d3b002547aaef0d62a739ea4fe63dbf29354b853","_id":"next-transpile-modules@9.1.0","_nodeVersion":"18.10.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-yzJji65xDqcIqjvx5vPJcs1M+MYQTzLM1pXH/qf8Q88ohx+bwVGDc1AeV+HKr1NwvMCNTpwVPSFI7cA5WdyeWA==","shasum":"dffd2563bf76f8afdb28f0611948f46252ca65ef","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-9.1.0.tgz","fileCount":5,"unpackedSize":26335,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDBzyaXQz8CbRrWVCITLeLIiF4YMZzzWg2c+vRkF1IslQIgDU1i6sxOAG2iwafyYvY4tAJMLbmzFAbGYkpdM7hQing="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjRDGbACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqhuBAAhmUyxenFXMq2V4o319NcaxysLn2LuKVVQItqmziXDKAh9IJJ\r\nNaQ8id336iAjpqaHzQdpUfiyHD216evcDxOI0RjWTza/Beiou30wIBUt9yF9\r\nHc2S6EO8j7W1flqgebiX2CPvUm5RTZa4Q5Q+S73T8CF/+xAic76s1zH+nRzQ\r\n8GR6xWaKgnouhHvFni4XCuUwiMZRktvItMW4OfeiAwRErvkZNnAtbbaInKIA\r\nbk0DvHitcGJ0HPUqDvDr1+C8cjz2PNwqEzDlfZyI72beTKBEleptmGW1iVgT\r\nSGyUHDG7aPQ+9DsVB7XA3ZYHZFORIhFm7Qjz9oBed0Fmoe4+CXOIQtV+0Nve\r\nmZ1qFfMumVA7KVdJUpJgMR8rxjv2MBAk+A0cK4v0aBhs4W8selHSx+tueOeZ\r\nA3W2dUuE/QcXcU8+mbKZ3+ZNayInJ6opWcReRd5U2Ik0nxniHNQBXUDuv2dj\r\n7eqVWdsrSCa5rBvDL3R8vjcIzhxE3tbKAvibXb1a0uTT029JfUImUWHsa8U4\r\n1oSFalkv2bpEUBAS57DT7X9HgzFv9kx6791brDGL0HfTuUEwQ/4SIKAirka1\r\nhUeJg6Je2k4M54XeE266yhcAdqqQpC3w21yATWf/WpzxKXNu62oImuihZuVl\r\nsjwLxgaDNveXmUv+h9Mt3UfP8X16/czrC9M=\r\n=yqQ9\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_9.1.0_1665413531479_0.2645660960562559"},"_hasShrinkwrap":false},"10.0.0":{"name":"next-transpile-modules","version":"10.0.0","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/swc/app run dev","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare:swc":"yarn --cwd src/__tests__/__apps__/swc/app run build","test:prepare:with-app-dir":"yarn --cwd src/__tests__/__apps__/with-app-dir/app run build","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:pnpm && npm run test:prepare:swc && npm run test:prepare:with-app-dir"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.10.0"},"devDependencies":{"@types/jest-environment-puppeteer":"5.0.2","eslint":"^8.25.0","eslint-config-prettier":"^8.5.0","eslint-config-semistandard":"^17.0.0","eslint-plugin-import":"^2.26.0","eslint-plugin-jest":"^27.1.1","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^6.0.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^10.1.0","jest":"^29.1.2","jest-environment-node":"^29.1.2","jest-environment-puppeteer":"^6.1.1","jest-puppeteer":"^6.1.1","prettier":"^2.7.1","prettier-eslint":"^15.0.1","puppeteer":"18.2.1","rewire":"^6.0.0","typescript":"^4.8.4","webpack":"^5.74.0"},"types":"./src/next-transpile-modules.d.ts","gitHead":"36ec35eff84c80d48e0b696439b1874594291e90","_id":"next-transpile-modules@10.0.0","_nodeVersion":"18.10.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-FyeJ++Lm2Fq31gbThiRCrJlYpIY9QaI7A3TjuhQLzOix8ChQrvn5ny4MhfIthS5cy6+uK1AhDRvxVdW17y3Xdw==","shasum":"7152880048835acb64d05fc7aa34910cbe7994da","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-10.0.0.tgz","fileCount":5,"unpackedSize":26982,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHY1fgHrPH7Gh1bXAxW/KGfx9R3O2c/itE/LINcHds3IAiEAic3Lw9QQhcsdD3lDaR0bf64TCFv+/z/2lGfWBnWVt0o="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjYUQFACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoxrQ//WjTJkqxf+8P0+aeuEjFUoqVkDaghl7HZzaKHc+/p6zD0JEl9\r\nwpceYclrTWNyalyVk94iySFWT3jQ+CSOHpP5bwz7wKmukhHAqoQXR2y4oh4p\r\nWHBpTchhv0ZHidu5gIRmw5uOscfF0WmmnFfyEwK26FyceFbPXPK87jXLYozg\r\nL/DPTMPDWHpN7K3FsvCrbzlFS+9xw0/0rnBNkjqYRHZy6tmcspNhfbQB3G+t\r\nOPb5pgUgxN/zx2KeRL5rJI01sKQqsFQdTjgxDRzFVMDlkFahiD0a+IJFWvvy\r\ny9WRY1JzxJjMIJnVit4xstv2xnEKi5XBk1oVQFspEkrlUmQ7/O9xxHncJdKQ\r\n4n+z4DMiSZy1JgMegGsB8jIWKodQjwpAHvdbYglrO9uyPESyeOA+xQmWVNfP\r\nkEf6a1QQtOPrMPmVjNUBJf1pev4jmstvg/kndd438FdGn4usElV0z46WO77C\r\nNAgOrKpgExBLVcqtWjAWlPW1oig1VJtS1yUnuybAfkgmY1nyVpkYpDNv4jNe\r\nV+tojU6AHABTUZ+YYVMxdWIuWth+u/chHFTb9y+56vKFYhzqUK1SyP4MYMab\r\nLabulw1kMcpSL5U+Xic+y6SRBGDpFBaJlgUpxiMp+w8pX+VXVHXd5if6lwky\r\nbyOE+xfGLYpsSHTCynTEcvZvlP1UJ+PfRLs=\r\n=LWbK\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_10.0.0_1667318788804_0.6518707717195524"},"_hasShrinkwrap":false},"10.0.1":{"name":"next-transpile-modules","version":"10.0.1","license":"MIT","author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"description":"Next.js plugin to transpile code from node_modules","main":"src/next-transpile-modules.js","scripts":{"setup":"node --trace-uncaught src/__tests__/setup.js","update:next":"npm run setup && bash scripts/next-update.sh","typings":"tsc","prepublishOnly":"npm run typings","pretest":"npm run setup","quickie":"node --trace-uncaught src/__tests__/setup.js && yarn --cwd src/__tests__/__apps__/swc/app run dev","test":"jest --forceExit","test:debug":"jest --detectOpenHandles --forceExit","test:lint":"eslint .","test:formatting":"prettier --check \"**/*.js\"","test:formatting:fix":"prettier --check \"**/*.js\" --write","test:prepare:npm-basic":"npm run build --prefix=src/__tests__/__apps__/npm-basic","test:prepare:yarn-workspaces":"yarn --cwd src/__tests__/__apps__/yarn-workspaces/app run build","test:prepare:yarn-workspaces-symlinks":"yarn --cwd src/__tests__/__apps__/yarn-workspaces-symlinks/app run build","test:prepare:pnpm":"npm run build --prefix=src/__tests__/__apps__/pnpm","test:prepare:swc":"yarn --cwd src/__tests__/__apps__/swc/app run build","test:prepare:with-app-dir":"yarn --cwd src/__tests__/__apps__/with-app-dir/app run build","test:prepare":"npm run test:prepare:npm-basic && npm run test:prepare:yarn-workspaces && npm run test:prepare:yarn-workspaces-symlinks && npm run test:prepare:pnpm && npm run test:prepare:swc && npm run test:prepare:with-app-dir"},"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"dependencies":{"enhanced-resolve":"^5.10.0"},"devDependencies":{"@types/jest-environment-puppeteer":"5.0.3","eslint":"^8.45.0","eslint-config-prettier":"^8.8.0","eslint-config-semistandard":"^17.0.0","eslint-plugin-import":"^2.27.5","eslint-plugin-jest":"^27.2.3","eslint-plugin-node":"^11.1.0","eslint-plugin-promise":"^6.1.1","eslint-plugin-standard":"^5.0.0","fs-extra":"^11.1.1","jest":"^29.6.1","jest-environment-node":"^29.6.1","jest-environment-puppeteer":"^9.0.0","jest-puppeteer":"^9.0.0","prettier":"^3.0.0","prettier-eslint":"^15.0.1","puppeteer":"20.9.0","rewire":"^6.0.0","typescript":"^5.1.6","webpack":"^5.88.2"},"types":"./src/next-transpile-modules.d.ts","gitHead":"f3c15d7559319c9853665f3348161286d1e8f3fc","_id":"next-transpile-modules@10.0.1","_nodeVersion":"18.17.0","_npmVersion":"9.6.7","dist":{"integrity":"sha512-4VX/LCMofxIYAVV58UmD+kr8jQflpLWvas/BQ4Co0qWLWzVh06FoZkECkrX5eEZT6oJFqie6+kfbTA3EZCVtdQ==","shasum":"1ca2b735b14781f4792f6214f808b600574e0348","tarball":"https://registry.npmjs.org/next-transpile-modules/-/next-transpile-modules-10.0.1.tgz","fileCount":5,"unpackedSize":27947,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFF1D1+SHcM4Abel+FUK3P0ct2/+m769gLY1U+xLPPrFAiB8ISg4Brd2cG1iGV2NgPTNsFZonPWAguh7XDLveH1trw=="}]},"_npmUser":{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"},"directories":{},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-transpile-modules_10.0.1_1690200223060_0.6032551900391194"},"_hasShrinkwrap":false}},"time":{"created":"2019-02-12T14:37:23.059Z","2.0.0":"2019-02-12T14:37:23.149Z","modified":"2023-07-24T12:03:43.512Z","1.1.0":"2019-02-12T14:49:39.514Z","2.1.0":"2019-03-01T20:06:40.243Z","1.2.0":"2019-03-01T20:13:22.695Z","1.3.0":"2019-03-05T19:44:16.524Z","2.2.0":"2019-03-05T19:48:25.404Z","2.3.0":"2019-04-17T08:13:39.340Z","2.3.1":"2019-04-17T09:03:46.745Z","3.0.0":"2020-01-20T12:45:36.569Z","3.0.1":"2020-01-21T21:04:52.059Z","3.0.2":"2020-01-23T16:56:32.643Z","3.1.0":"2020-03-10T15:59:02.197Z","3.2.0":"2020-04-03T21:33:27.168Z","3.3.0":"2020-04-28T08:47:56.346Z","4.0.0":"2020-07-27T18:34:39.227Z","4.0.1":"2020-07-28T16:30:33.621Z","4.0.2":"2020-07-29T12:07:17.743Z","4.0.3":"2020-08-11T15:35:21.416Z","4.1.0":"2020-08-12T11:34:48.347Z","5.0.0-beta.0":"2020-11-13T13:51:03.816Z","5.0.0-beta.1":"2020-11-13T14:04:44.314Z","5.0.0-beta.2":"2020-11-13T14:07:10.803Z","5.0.0-beta.3":"2020-11-13T14:26:06.951Z","5.0.0-beta.4":"2020-11-13T15:40:16.048Z","5.0.0-beta.5":"2020-11-13T15:48:20.183Z","5.0.0-beta.6":"2020-11-25T12:33:31.364Z","5.0.0-beta.7":"2020-11-25T12:46:37.660Z","5.0.0-beta.8":"2020-11-25T13:09:47.042Z","5.0.0-beta.9":"2020-11-25T13:13:20.036Z","5.0.0-beta.10":"2020-11-25T13:29:48.303Z","5.0.0-beta.11":"2020-11-25T13:32:57.519Z","5.0.0-beta.12":"2020-11-25T14:33:55.466Z","5.0.0-beta.13":"2020-11-25T14:37:35.896Z","5.0.0-beta.14":"2020-11-25T14:39:29.126Z","5.0.0-beta.15":"2020-11-25T14:45:00.472Z","5.0.0":"2020-11-26T12:37:08.114Z","6.0.0":"2020-12-02T10:00:45.943Z","6.1.0":"2021-01-27T15:43:07.383Z","6.2.0":"2021-02-04T03:01:18.495Z","6.3.0":"2021-02-08T14:53:50.863Z","6.4.0":"2021-03-31T21:25:19.559Z","6.4.1":"2021-04-26T07:58:43.565Z","7.0.0":"2021-04-28T19:22:45.062Z","7.1.0":"2021-05-17T20:20:40.826Z","7.1.1":"2021-05-18T09:57:08.533Z","7.1.2":"2021-05-19T14:23:58.023Z","7.2.0":"2021-05-21T12:29:22.321Z","7.3.0":"2021-06-09T22:20:41.537Z","8.0.0":"2021-06-15T18:56:29.098Z","9.0.0":"2021-10-27T09:26:00.866Z","9.1.0":"2022-10-10T14:52:11.692Z","10.0.0":"2022-11-01T16:06:29.009Z","10.0.1":"2023-07-24T12:03:43.318Z"},"maintainers":[{"name":"martpie","email":"pierre.de.la.martiniere@gmail.com"}],"description":"Next.js plugin to transpile code from node_modules","homepage":"https://github.com/martpie/next-transpile-modules#readme","keywords":["next","next.js","plugin","transpile","modules","babel","webpack"],"repository":{"type":"git","url":"git+https://github.com/martpie/next-transpile-modules.git"},"author":{"name":"Pierre de la Martinière","email":"pierre.de.la.martiniere@gmail.com"},"bugs":{"url":"https://github.com/martpie/next-transpile-modules/issues"},"license":"MIT","readme":"> **Note**\n> All `next-transpile-modules` features have natively landed to Next.js 13.1, you can check [the migration guide here](https://github.com/martpie/next-transpile-modules/releases/tag/the-end).\n>\n> This package is now officially deprecated and on life-support.\n>\n> PRs with fixes are welcome and I will help review them, but that's it. I **highly** recommend contributing to Next.js in case your setup is not working there.\n\n---\n\n# Next.js + Transpile `node_modules`\n\n![Build Status](https://github.com/martpie/next-transpile-modules/workflows/tests/badge.svg)\n\nTranspile modules from `node_modules` using the Next.js Babel configuration.\n\nMakes it easy to have local libraries and keep a slick, manageable dev experience.\n\n- Supports transpilation of all extensions supported by Next.js: `.js`, `.jsx`, `.ts`, `.tsx`, `.mjs`, `.css`, `.scss` and `.sass`\n- Enable hot-reloading on local packages\n- Enable global and local CSS loading from local/npm packages\n- Most setups should work out of the box (npm, yarn, pnpm, ...)\n\n## What problems does it solve?\n\nThis plugin aims to solve the following challenges:\n\n- code transpilation from local packages (think: a monorepo with a `styleguide` package)\n- code transpilation from NPM modules using ES6 imports (e.g `lodash-es`)\n\nWhat this plugin **does not aim** to solve:\n\n- any-package IE11-compatible maker\n\n## Compatibility table\n\n| Next.js version   | Plugin version     |\n| ----------------- | ------------------ |\n| Next.js 13        | 10.x               |\n| Next.js 12        | 9.x                |\n| Next.js 11        | 8.x                |\n| Next.js 9.5+ / 10 | 4.x, 5.x, 6.x, 7.x |\n| Next.js 9.2       | 3.x                |\n| Next.js 8 / 9     | 2.x                |\n| Next.js 6 / 7     | 1.x                |\n\nLatest Next.js version tested: **13.4.12**.\n\n## Installation\n\n```\nnpm install --save next-transpile-modules\n```\n\nor\n\n```\nyarn add next-transpile-modules\n```\n\n## Usage\n\n### withTM(transpileModules [, options])\n\n- `transpileModules` String[]: modules to be transpiled\n- `options` Object (optional)\n  - `resolveSymlinks` Boolean: Enable symlinks resolution to their real path by Webpack (default to `true`)\n  - `debug` Boolean: Display some informative logs in the console (can get noisy!) (default to `false`)\n  - `__unstable_matcher` (path) => boolean: Custom matcher that will override the default one. Don't use it.\n\n#### Note on `resolveSymlinks`\n\nNode.js resolution is based on the fact that symlinks are resolved. Not resolving them will alter the behavior, but there are some cases where the alternative behavior makes things a lot easier.\n\nIf:\n\n- You are using `npm/yarn link` to link packages into node_modules.\n- You are using `npm` with `file:` dependencies that live outside of your project directory\n  - `npm` will create symlinks in this case. Yarn will copy instead.\n\n**you should set `resolveSymlinks: false`**, which results which will make things work as expected.\n\nFor other scenarios like:\n\n- `pnpm`\n- `yarn/npm` workspaces\n- `yarn 2` portals\n\nyou should keep `resolveSymlinks: true` (default).\n\n#### Examples\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['somemodule', 'and-another']); // pass the modules you would like to see transpiled\n\nmodule.exports = withTM({});\n```\n\n**Notes:**\n\n- please declare `withTM` as your last plugin (the outermost one).\n- ~~make sure all your packages have [a valid `main` field](https://docs.npmjs.com/cli/v6/configuring-npm/package-json#main).~~ (not needed anymore since `7.1.0`)\n- there is currently no way to transpile only parts of a package, it's all or nothing\n\n### Scoped packages\n\nYou can include scoped packages or nested ones:\n\n```js\nconst withTM = require('next-transpile-modules')(['@shared/ui', '@shared/utils']);\n\n// ...\n```\n\n```js\nconst withTM = require('next-transpile-modules')(['styleguide/node_modules/lodash-es']);\n\n// ...\n```\n\nIf you need to install all packages of a certain scope (**it is highly discouraged**), you can do the following:\n\n```js\nconst packageJSON = require('./package.json');\nconst transpiledPackages = Object.keys(packageJSON.dependencies).filter((it) => it.includes('@shared/'));\n\nconst withTM = require('next-transpile-modules')(transpiledPackages);\n```\n\n### With `next-compose-plugins`:\n\n```js\nconst withPlugins = require('next-compose-plugins');\nconst withTM = require('next-transpile-modules')(['some-module', 'and-another']);\n\nmodule.exports = withPlugins([withTM], {\n  // ...\n});\n```\n\n### CSS/SCSS support\n\nSince `next-transpile-modules@3` and `next@>9.2`, this plugin can also transpile CSS included in your transpiled packages. SCSS/SASS is also supported since `next-transpile-modules@3.1.0`.\n\nIn your transpiled package:\n\n```js\n// shared-ui/components/Button.js\nimport styles from './Button.module.css';\n\nfunction Button(props) {\n  return (\n    <button type='button' className={styles.error}>\n      {props.children}\n    </button>\n  );\n}\n\nexport default Button;\n```\n\n```css\n/* shared-ui/components/Button.module.css */\n.error {\n  color: white;\n  background-color: red;\n}\n```\n\nIn your app:\n\n```js\n// next.config.js\nconst withTM = require('next-transpile-modules')(['shared-ui']);\n\n// ...\n```\n\n```jsx\n// pages/home.jsx\nimport React from 'react';\nimport Button from 'shared-ui/components/Button';\n\nconst HomePage = () => {\n  return (\n    <main>\n      {/* will output <button class=\"Button_error__xxxxx\"> */}\n      <Button>Styled button</Button>\n    </main>\n  );\n};\n\nexport default HomePage;\n```\n\nIt also supports global CSS import packages located in `node_modules`:\n\n```jsx\n// pages/_app.js\nimport 'shared-ui/styles/global.css'; // will be imported globally\n\nexport default function MyApp({ Component, pageProps }) {\n  return <Component {...pageProps} />;\n}\n```\n\n## Contributing\n\n- clone\n- `cd next-transpile-modules`\n- `yarn`\n\nIf you want to update the Next.js tested version:\n\n- update `scripts/next-update.sh` with the latest Next.js version\n- make sure `npm`, `yarn` and `pnpm` are installed\n- `yarn setup`\n- `bash scripts/next-update.sh`\n\nPush your changes and Github Actions will test everything as it should be.\n\n## FAQ\n\n### What is the difference with `@weco/next-plugin-transpile-modules`?\n\n- it is maintained, `@weco`'s seems dead\n- it supports TypeScript\n- it supports CSS modules (since Next.js 9.2)\n- it supports `.mjs`\n\n### Where can I find a setup that works?\n\n[Here you go](https://github.com/martpie/monorepo-typescript-next-the-sane-way)!\n\n### A new version of Next.js is available/I just setup my project, and my build is breaking because of this plugin\n\nIt is important to understand that this plugin is a big hack of the Next.js Webpack configuration. When the Next.js team pushes an update to their build configuration, the changes `next-transpile-modules` bring may be outdated, and the plugin needs to be updated (which is a breaking change for this plugin, as the updated plugin is usually not retro-compatible with the previous versions of Next.js).\n\nNow, this build problem can happen when you install your dependencies with `npm install`/`yarn install` (in your CI pipeline for example). Those commands **may re-resolve your `next` dependency of your `package.json` to a newer one**, and this newer one may have critical Webpack changes, hence breaking your build.\n\nThe way to fix it is easy, and it is what you should always do: **install your dependencies with `npm ci` (\"clean install\") or `yarn --frozen-lockfile`**. This will force `npm` or `yarn` to use the version of Next.js declared in your lock file, instead of downloading the latest one compatible with the version accepted by your `package.json`.\n\nSo basically: use your lock files right, and understand what problems they are solving ;)\n\nmore:\n\n- check the [compatibility table](#compatibility-table) of this plugin\n- read more about semver and version resolutions: https://docs.npmjs.com/misc/semver\n\n### I have trouble making it work after upgrading to v5/v6\n\nPlease make sure to [read the changelog](https://github.com/martpie/next-transpile-modules/releases).\n\n### I have trouble with transpilation and my custom `.babelrc`\n\nIf you get a transpilation error when using a custom Babel configuration, make sure you are using a `babel.config.js` and not a `.babelrc`.\n\nThe former is [a project-wide Babel configuration](https://babeljs.io/docs/en/config-files), when the latter works for relative paths only (and may not work for Yarn for example, as it installs dependencies in a parent directory).\n\n### I have trouble with Yarn and hot reloading\n\nIf you add a local library (let's say with `yarn add ../some-shared-module`), Yarn will copy those files by default, instead of symlinking them. So your changes to the initial folder won't be copied to your Next.js `node_modules` directory.\n\nYou can go back to `npm`, or use Yarn workspaces. See [an example](https://github.com/zeit/next.js/tree/canary/examples/with-yarn-workspaces) in the official Next.js repo.\n\n### How do I find out which package is causing a runtime exception?\n\n- add `config.optimization.minimize = false;` to you `next.config.js`'s Webpack configuration\n- run a production build\n- run it on the browser throwing the error\n- open the console, jump to the line where it failed\n- goes a little bit up in the lines of code, and check the Webpack comments telling you which module is affected\n\n### I have trouble making it work with Lerna\n\nLerna's purpose is to publish different packages from a monorepo, **it does not help for and does not intend to help local development with local modules** (<- this, **IN CAPS**).\n\nThis is not coming from me, but [from Lerna's maintainer](https://github.com/lerna/lerna/issues/1243#issuecomment-401396850).\n\nSo you are probably [using it wrong](https://github.com/martpie/next-transpile-modules/issues/5#issuecomment-441501107), and I advice you to use `npm` or Yarn workspaces instead.\n\n### But... I really need to make it work with Lerna!\n\nAgain, most probably a bad idea. You may need to tell your Webpack configuration how to properly resolve your scoped packages, as they won't be installed in your Next.js directory, but the root of your Lerna setup.\n\n```js\nconst withTM = require('next-transpile-modules')(['@your-project/shared', '@your-project/styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n    config.resolve.alias = {\n      ...config.resolve.alias,\n      // Will make webpack look for these modules in parent directories\n      '@your-project/shared': require.resolve('@your-project/shared'),\n      '@your-project/styleguide': require.resolve('@your-project/styleguide'),\n      // ...\n    };\n    return config;\n  },\n});\n```\n\n### I have trouble with duplicated dependencies or the `Invalid hook call` error in `react`\n\nIt can happen that when using `next-transpile-modules` with a local package and `npm`, you end up with duplicated dependencies in your final Next.js build. It is important to understand _why_ it happens.\n\nLet's take the following setup: one Next.js app (\"Consumer\"), and one Styleguide library.\n\nYou will probably have `react` as a `peerDependencies` and as a `devDependecy` of the Styleguide. If you use `npm i`, it will create a symlink to your Styleguide package in your \"Consumer\" `node_modules`.\n\nThe thing is in this shared package, you also have a `node_modules`. So when your shared modules requires, let's say `react`, Webpack will resolve it to the version in your Styleguide's `node_modules`, and not your Consumer's `node_modules`. Hence the duplicated `react` in your final bundles.\n\nYou can tell Webpack how to resolve the `react` of your Styleguide to use the version in your Next.js app like that:\n\n```diff\nconst withTM = require('next-transpile-modules')(['styleguide']);\n\nmodule.exports = withTM({\n  webpack: (config, options) => {\n+   if (options.isServer) {\n+     config.externals = ['react', ...config.externals];\n+   }\n+\n+   config.resolve.alias['react'] = path.resolve(__dirname, '.', 'node_modules', 'react');\n\n    return config\n  },\n});\n```\n\nPlease note, the above [will only work](https://github.com/zeit/next.js/issues/9022#issuecomment-610255555) if `react` is properly declared as `peerDependencies` or `devDependencies` in your referenced package.\n\nIt is not a great solution, but it works. Any help to find a more future-proof solution is welcome.\n\n## Credits\n\nAll the honor goes to [James Gorrie](https://github.com/jamesgorrie) who created the first version of this plugin.\n","readmeFilename":"README.md"}