From ec7c71c4e9e2db9e6aff2137c56cb2c9fdf99087 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 16 May 2023 08:51:42 +0000 Subject: [PATCH 1/2] Bump rollup to ^3.21.8 --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 642ac3af1d83fe..c3d6a5ea7afc88 100644 --- a/package.json +++ b/package.json @@ -180,7 +180,7 @@ "react-test-renderer": "^18.2.0", "remark": "^13.0.0", "rimraf": "^3.0.2", - "rollup": "^2.79.1", + "rollup": "^3.21.8", "rollup-plugin-babel": "^4.4.0", "rollup-plugin-commonjs": "^10.1.0", "rollup-plugin-node-globals": "^1.4.0", diff --git a/yarn.lock b/yarn.lock index 08a357491e9ce5..9b16c16a6809e4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -14533,10 +14533,10 @@ rollup-pluginutils@^2.3.1, rollup-pluginutils@^2.8.1: dependencies: estree-walker "^0.6.1" -rollup@^2.79.1: - version "2.79.1" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.79.1.tgz#bedee8faef7c9f93a2647ac0108748f497f081c7" - integrity sha512-uKxbd0IhMZOhjAiD5oAFp7BqvkA4Dv47qpOCtaNvng4HBwdbWtdOh8f5nZNuk2rp51PMGk3bzfWu5oayNEuYnw== +rollup@^3.21.8: + version "3.21.8" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-3.21.8.tgz#fc768008fe2c953f18210370fd70fe1ffff59e2c" + integrity sha512-SSFV2T2fWtQ/vvBip85u2Nr0GNKireabH9d7nXswBg+XSH+jbVDSYptRAEbCEsquhs503rpPA9POYAp0/Jhasw== optionalDependencies: fsevents "~2.3.2" From caaaaecc6d57bb43df0da6b01cc63bc75fd66b93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Dudak?= Date: Tue, 16 May 2023 12:17:04 +0200 Subject: [PATCH 2/2] Update Material UI's rollup config --- packages/mui-material/package.json | 2 +- .../scripts/{rollup.config.js => rollup.config.mjs} | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) rename packages/mui-material/scripts/{rollup.config.js => rollup.config.mjs} (96%) diff --git a/packages/mui-material/package.json b/packages/mui-material/package.json index 7b306e9da55e35..7e356c53e03c85 100644 --- a/packages/mui-material/package.json +++ b/packages/mui-material/package.json @@ -32,7 +32,7 @@ "build:modern": "node ../../scripts/build.mjs modern", "build:node": "node ../../scripts/build.mjs node", "build:stable": "node ../../scripts/build.mjs stable", - "build:umd": "cross-env BABEL_ENV=stable rollup -c scripts/rollup.config.js", + "build:umd": "cross-env BABEL_ENV=stable rollup -c scripts/rollup.config.mjs", "build:copy-files": "node ../../scripts/copyFiles.mjs", "build:types": "node ../../scripts/buildTypes.mjs", "prebuild": "rimraf build tsconfig.build.tsbuildinfo", diff --git a/packages/mui-material/scripts/rollup.config.js b/packages/mui-material/scripts/rollup.config.mjs similarity index 96% rename from packages/mui-material/scripts/rollup.config.js rename to packages/mui-material/scripts/rollup.config.mjs index d2c908030ba59f..e0a12478e4c95d 100644 --- a/packages/mui-material/scripts/rollup.config.js +++ b/packages/mui-material/scripts/rollup.config.mjs @@ -2,6 +2,7 @@ import { promises as fs, existsSync } from 'fs'; import path from 'path'; import zlib from 'zlib'; import { promisify } from 'util'; +import * as url from 'url'; import nodeResolve from 'rollup-plugin-node-resolve'; import commonjs from 'rollup-plugin-commonjs'; import babel from 'rollup-plugin-babel'; @@ -10,6 +11,7 @@ import nodeGlobals from 'rollup-plugin-node-globals'; import { terser } from 'rollup-plugin-terser'; const gzip = promisify(zlib.gzip); +const currentDirectory = url.fileURLToPath(new URL('.', import.meta.url)); /** * @param {{snapshotPath: string}} options @@ -77,7 +79,7 @@ function sizeSnapshot(options) { function resolveNestedImport(packageFolder, importee) { const folder = importee.split('/')[2]; const resolvedFilename = path.resolve( - __dirname, + currentDirectory, `../../../packages/${packageFolder}/src/${folder}/index`, ); @@ -124,7 +126,7 @@ const babelOptions = { // We are using @babel/plugin-transform-runtime runtimeHelpers: true, extensions: ['.js', '.ts', '.tsx'], - configFile: path.resolve(__dirname, '../../../babel.config.js'), + configFile: path.resolve(currentDirectory, '../../../babel.config.js'), }; const commonjsOptions = { ignoreGlobal: true,