From 7dadf284873744e29a362bb64fb4e8e48afdac7d Mon Sep 17 00:00:00 2001 From: Bob Ippolito Date: Mon, 13 Jan 2025 16:04:16 -0800 Subject: [PATCH 1/7] remove @ampproject/rollup-plugin-closure-compiler --- package-lock.json | 234 ---------------------------------------------- package.json | 1 - scripts/build.js | 25 +---- 3 files changed, 4 insertions(+), 256 deletions(-) diff --git a/package-lock.json b/package-lock.json index 423afc85aee..04863bf15dd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,7 +15,6 @@ "yjs": "^13.5.42" }, "devDependencies": { - "@ampproject/rollup-plugin-closure-compiler": "^0.27.0", "@babel/core": "^7.24.5", "@babel/eslint-parser": "^7.24.5", "@babel/plugin-transform-optional-catch-binding": "^7.24.1", @@ -657,121 +656,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@ampproject/remapping": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-0.2.0.tgz", - "integrity": "sha512-a4EztS9/GOVQjX5Ol+Iz33TFhaXvYBF7aB6D8+Qz0/SCIxOm3UNRhGZiwcCuJ8/Ifc6NCogp3S48kc5hFxRpUw==", - "dev": true, - "dependencies": { - "@jridgewell/resolve-uri": "1.0.0", - "sourcemap-codec": "1.4.8" - }, - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/@ampproject/rollup-plugin-closure-compiler": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@ampproject/rollup-plugin-closure-compiler/-/rollup-plugin-closure-compiler-0.27.0.tgz", - "integrity": "sha512-stpAOn2ZZEJuAV39HFw9cnKJYNhEeHtcsoa83orpLDhSxsxSbVEKwHaWlFBaQYpQRSOdapC4eJhJnCzocZxnqg==", - "dev": true, - "dependencies": { - "@ampproject/remapping": "0.2.0", - "acorn": "7.3.1", - "acorn-walk": "7.1.1", - "estree-walker": "2.0.1", - "google-closure-compiler": "20210808.0.0", - "magic-string": "0.25.7", - "uuid": "8.1.0" - }, - "engines": { - "node": ">=10" - }, - "peerDependencies": { - "rollup": ">=1.27" - } - }, - "node_modules/@ampproject/rollup-plugin-closure-compiler/node_modules/google-closure-compiler": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler/-/google-closure-compiler-20210808.0.0.tgz", - "integrity": "sha512-+R2+P1tT1lEnDDGk8b+WXfyVZgWjcCK9n1mmZe8pMEzPaPWxqK7GMetLVWnqfTDJ5Q+LRspOiFBv3Is+0yuhCA==", - "dev": true, - "dependencies": { - "chalk": "2.x", - "google-closure-compiler-java": "^20210808.0.0", - "minimist": "1.x", - "vinyl": "2.x", - "vinyl-sourcemaps-apply": "^0.2.0" - }, - "bin": { - "google-closure-compiler": "cli.js" - }, - "engines": { - "node": ">=10" - }, - "optionalDependencies": { - "google-closure-compiler-linux": "^20210808.0.0", - "google-closure-compiler-osx": "^20210808.0.0", - "google-closure-compiler-windows": "^20210808.0.0" - } - }, - "node_modules/@ampproject/rollup-plugin-closure-compiler/node_modules/google-closure-compiler-java": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-java/-/google-closure-compiler-java-20210808.0.0.tgz", - "integrity": "sha512-7dEQfBzOdwdjwa/Pq8VAypNBKyWRrOcKjnNYOO9gEg2hjh8XVMeQzTqw4uANfVvvANGdE/JjD+HF6zHVgLRwjg==", - "dev": true - }, - "node_modules/@ampproject/rollup-plugin-closure-compiler/node_modules/google-closure-compiler-linux": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-linux/-/google-closure-compiler-linux-20210808.0.0.tgz", - "integrity": "sha512-byKi5ITUiWRvEIcQo76i1siVnOwrTmG+GNcBG4cJ7x8IE6+4ki9rG5pUe4+DOYHkfk52XU6XHt9aAAgCcFDKpg==", - "cpu": [ - "x64", - "x86" - ], - "dev": true, - "optional": true, - "os": [ - "linux" - ] - }, - "node_modules/@ampproject/rollup-plugin-closure-compiler/node_modules/google-closure-compiler-osx": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-osx/-/google-closure-compiler-osx-20210808.0.0.tgz", - "integrity": "sha512-iwyAY6dGj1FrrBdmfwKXkjtTGJnqe8F+9WZbfXxiBjkWLtIsJt2dD1+q7g/sw3w8mdHrGQAdxtDZP/usMwj/Rg==", - "cpu": [ - "x64", - "x86", - "arm64" - ], - "dev": true, - "optional": true, - "os": [ - "darwin" - ] - }, - "node_modules/@ampproject/rollup-plugin-closure-compiler/node_modules/google-closure-compiler-windows": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-windows/-/google-closure-compiler-windows-20210808.0.0.tgz", - "integrity": "sha512-VI+UUYwtGWDYwpiixrWRD8EklHgl6PMbiEaHxQSrQbH8PDXytwaOKqmsaH2lWYd5Y/BOZie2MzjY7F5JI69q1w==", - "cpu": [ - "x64" - ], - "dev": true, - "optional": true, - "os": [ - "win32" - ] - }, - "node_modules/@ampproject/rollup-plugin-closure-compiler/node_modules/uuid": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.1.0.tgz", - "integrity": "sha512-CI18flHDznR0lq54xBycOVmphdCYnQLKn8abKn7PXUiKUGdEd+/l9LWNJmugXel4hXq7S+RMNl34ecyC9TntWg==", - "dev": true, - "bin": { - "uuid": "dist/bin/uuid" - } - }, "node_modules/@babel/code-frame": { "version": "7.26.2", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.26.2.tgz", @@ -6754,15 +6638,6 @@ "node": ">=6.0.0" } }, - "node_modules/@jridgewell/resolve-uri": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-1.0.0.tgz", - "integrity": "sha512-9oLAnygRMi8Q5QkYEU4XWK04B+nuoXoxjRvRxgjuChkLZFBja0YPSgdZ7dZtwhncLBcQe/I/E+fLuk5qxcYVJA==", - "dev": true, - "engines": { - "node": ">=6.0.0" - } - }, "node_modules/@jridgewell/set-array": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", @@ -10310,15 +10185,6 @@ "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, - "node_modules/acorn-walk": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-7.1.1.tgz", - "integrity": "sha512-wdlPY2tm/9XBr7QkKlq0WQVgiuGTX6YWPyRyBviSoScBuLfTVQhvwg6wJ369GJ/1nPfTLMfnrFIfjqVg6d+jQQ==", - "dev": true, - "engines": { - "node": ">=0.4.0" - } - }, "node_modules/address": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/address/-/address-1.2.0.tgz", @@ -18079,12 +17945,6 @@ "integrity": "sha512-ko/gIFJRv177XgZsZcBwnqJN5x/Gien8qNOn0D5bQU/zAzVf9Zt3BlcUiLqhV9y4ARk0GbT3tnUiPNgnTXzc/Q==", "license": "MIT" }, - "node_modules/estree-walker": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.1.tgz", - "integrity": "sha512-tF0hv+Yi2Ot1cwj9eYHtxC0jB9bmjacjQs6ZBTj82H8JwUywFuc+7E83NWfNMwHXZc11mjfFcVXPe9gEP4B8dg==", - "dev": true - }, "node_modules/esutils": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", @@ -39758,82 +39618,6 @@ "integrity": "sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw==", "dev": true }, - "@ampproject/remapping": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-0.2.0.tgz", - "integrity": "sha512-a4EztS9/GOVQjX5Ol+Iz33TFhaXvYBF7aB6D8+Qz0/SCIxOm3UNRhGZiwcCuJ8/Ifc6NCogp3S48kc5hFxRpUw==", - "dev": true, - "requires": { - "@jridgewell/resolve-uri": "1.0.0", - "sourcemap-codec": "1.4.8" - } - }, - "@ampproject/rollup-plugin-closure-compiler": { - "version": "0.27.0", - "resolved": "https://registry.npmjs.org/@ampproject/rollup-plugin-closure-compiler/-/rollup-plugin-closure-compiler-0.27.0.tgz", - "integrity": "sha512-stpAOn2ZZEJuAV39HFw9cnKJYNhEeHtcsoa83orpLDhSxsxSbVEKwHaWlFBaQYpQRSOdapC4eJhJnCzocZxnqg==", - "dev": true, - "requires": { - "@ampproject/remapping": "0.2.0", - "acorn": "7.3.1", - "acorn-walk": "7.1.1", - "estree-walker": "2.0.1", - "google-closure-compiler": "20210808.0.0", - "magic-string": "0.25.7", - "uuid": "8.1.0" - }, - "dependencies": { - "google-closure-compiler": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler/-/google-closure-compiler-20210808.0.0.tgz", - "integrity": "sha512-+R2+P1tT1lEnDDGk8b+WXfyVZgWjcCK9n1mmZe8pMEzPaPWxqK7GMetLVWnqfTDJ5Q+LRspOiFBv3Is+0yuhCA==", - "dev": true, - "requires": { - "chalk": "2.x", - "google-closure-compiler-java": "^20210808.0.0", - "google-closure-compiler-linux": "^20210808.0.0", - "google-closure-compiler-osx": "^20210808.0.0", - "google-closure-compiler-windows": "^20210808.0.0", - "minimist": "1.x", - "vinyl": "2.x", - "vinyl-sourcemaps-apply": "^0.2.0" - } - }, - "google-closure-compiler-java": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-java/-/google-closure-compiler-java-20210808.0.0.tgz", - "integrity": "sha512-7dEQfBzOdwdjwa/Pq8VAypNBKyWRrOcKjnNYOO9gEg2hjh8XVMeQzTqw4uANfVvvANGdE/JjD+HF6zHVgLRwjg==", - "dev": true - }, - "google-closure-compiler-linux": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-linux/-/google-closure-compiler-linux-20210808.0.0.tgz", - "integrity": "sha512-byKi5ITUiWRvEIcQo76i1siVnOwrTmG+GNcBG4cJ7x8IE6+4ki9rG5pUe4+DOYHkfk52XU6XHt9aAAgCcFDKpg==", - "dev": true, - "optional": true - }, - "google-closure-compiler-osx": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-osx/-/google-closure-compiler-osx-20210808.0.0.tgz", - "integrity": "sha512-iwyAY6dGj1FrrBdmfwKXkjtTGJnqe8F+9WZbfXxiBjkWLtIsJt2dD1+q7g/sw3w8mdHrGQAdxtDZP/usMwj/Rg==", - "dev": true, - "optional": true - }, - "google-closure-compiler-windows": { - "version": "20210808.0.0", - "resolved": "https://registry.npmjs.org/google-closure-compiler-windows/-/google-closure-compiler-windows-20210808.0.0.tgz", - "integrity": "sha512-VI+UUYwtGWDYwpiixrWRD8EklHgl6PMbiEaHxQSrQbH8PDXytwaOKqmsaH2lWYd5Y/BOZie2MzjY7F5JI69q1w==", - "dev": true, - "optional": true - }, - "uuid": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.1.0.tgz", - "integrity": "sha512-CI18flHDznR0lq54xBycOVmphdCYnQLKn8abKn7PXUiKUGdEd+/l9LWNJmugXel4hXq7S+RMNl34ecyC9TntWg==", - "dev": true - } - } - }, "@babel/code-frame": { "version": "7.26.2", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.26.2.tgz", @@ -43922,12 +43706,6 @@ "@jridgewell/trace-mapping": "^0.3.24" } }, - "@jridgewell/resolve-uri": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-1.0.0.tgz", - "integrity": "sha512-9oLAnygRMi8Q5QkYEU4XWK04B+nuoXoxjRvRxgjuChkLZFBja0YPSgdZ7dZtwhncLBcQe/I/E+fLuk5qxcYVJA==", - "dev": true - }, "@jridgewell/set-array": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", @@ -46494,12 +46272,6 @@ "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==" }, - "acorn-walk": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-7.1.1.tgz", - "integrity": "sha512-wdlPY2tm/9XBr7QkKlq0WQVgiuGTX6YWPyRyBviSoScBuLfTVQhvwg6wJ369GJ/1nPfTLMfnrFIfjqVg6d+jQQ==", - "dev": true - }, "address": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/address/-/address-1.2.0.tgz", @@ -51895,12 +51667,6 @@ } } }, - "estree-walker": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.1.tgz", - "integrity": "sha512-tF0hv+Yi2Ot1cwj9eYHtxC0jB9bmjacjQs6ZBTj82H8JwUywFuc+7E83NWfNMwHXZc11mjfFcVXPe9gEP4B8dg==", - "dev": true - }, "esutils": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", diff --git a/package.json b/package.json index e2d6f27a456..15d059b8f62 100644 --- a/package.json +++ b/package.json @@ -110,7 +110,6 @@ "size": "npm run build-prod && size-limit" }, "devDependencies": { - "@ampproject/rollup-plugin-closure-compiler": "^0.27.0", "@babel/core": "^7.24.5", "@babel/eslint-parser": "^7.24.5", "@babel/plugin-transform-optional-catch-binding": "^7.24.1", diff --git a/scripts/build.js b/scripts/build.js index ec1b6c470f7..5d7b1045ced 100644 --- a/scripts/build.js +++ b/scripts/build.js @@ -18,7 +18,6 @@ const commonjs = require('@rollup/plugin-commonjs'); const replace = require('@rollup/plugin-replace'); const json = require('@rollup/plugin-json'); const alias = require('@rollup/plugin-alias'); -const compiler = require('@ampproject/rollup-plugin-closure-compiler'); const terser = require('@rollup/plugin-terser'); const {exec} = require('child-process-promise'); const {packagesManager} = require('./shared/packagesManager'); @@ -34,19 +33,6 @@ const isRelease = argv.release; const isWWW = argv.www; const extractCodes = argv.codes; -const closureOptions = { - apply_input_source_maps: false, - assume_function_wrapper: true, - compilation_level: 'SIMPLE', - inject_libraries: false, - language_in: 'ECMASCRIPT_2019', - language_out: 'ECMASCRIPT_2019', - process_common_js_modules: false, - rewrite_polyfills: false, - use_types_for_optimization: false, - warning_level: 'QUIET', -}; - const modulePackageMappings = Object.fromEntries( packagesManager.getPublicPackages().flatMap((pkg) => { const pkgName = pkg.getNpmName(); @@ -254,13 +240,10 @@ async function build( isWWW && strictWWWMappings, ), ), - // terser is used for esm builds because - // @ampproject/rollup-plugin-closure-compiler doesn't compile - // `export default function X()` correctly - isProd && - (format === 'esm' - ? terser({ecma: 2019, module: true}) - : compiler(closureOptions)), + // terser is used because @ampproject/rollup-plugin-closure-compiler + // doesn't compile `export default function X()` correctly and hasn't + // been updated since Aug 2021 + isProd && terser({ecma: 2019, module: format === 'esm'}), { renderChunk(source) { // Assets pipeline might use "export" word in the beginning of the line From 33c6c9d6fc6751f963b18f4fadbff4acaa44c212 Mon Sep 17 00:00:00 2001 From: Bob Ippolito Date: Mon, 13 Jan 2025 17:55:00 -0800 Subject: [PATCH 2/7] change size-limit from pull_request_target pull_request --- .github/workflows/size-limit.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/size-limit.yml b/.github/workflows/size-limit.yml index 35467b538d8..a2d05005781 100644 --- a/.github/workflows/size-limit.yml +++ b/.github/workflows/size-limit.yml @@ -1,6 +1,6 @@ name: 'Bundles' on: - pull_request_target: + pull_request: branches: - main jobs: From 67dfed5ded74785643824acbf3309ed37a0bc528 Mon Sep 17 00:00:00 2001 From: Bob Ippolito Date: Mon, 13 Jan 2025 20:05:17 -0800 Subject: [PATCH 3/7] Revert "change size-limit from pull_request_target pull_request" This reverts commit 33c6c9d6fc6751f963b18f4fadbff4acaa44c212. --- .github/workflows/size-limit.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/size-limit.yml b/.github/workflows/size-limit.yml index a2d05005781..35467b538d8 100644 --- a/.github/workflows/size-limit.yml +++ b/.github/workflows/size-limit.yml @@ -1,6 +1,6 @@ name: 'Bundles' on: - pull_request: + pull_request_target: branches: - main jobs: From 1cc29b9e91b9befca5ea2540ab98c7970ef984cc Mon Sep 17 00:00:00 2001 From: Bob Ippolito Date: Mon, 13 Jan 2025 20:25:08 -0800 Subject: [PATCH 4/7] check out merge commit --- .github/workflows/size-limit.yml | 67 ++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/.github/workflows/size-limit.yml b/.github/workflows/size-limit.yml index 35467b538d8..5b8bef8bbc2 100644 --- a/.github/workflows/size-limit.yml +++ b/.github/workflows/size-limit.yml @@ -9,7 +9,74 @@ jobs: env: CI_JOB_NUMBER: 1 steps: + # See also: + # https://github.com/facebook/lexical/issues/6852 + # https://github.com/NixOS/nixpkgs/blob/c8db8bd9656ee3d373ce9445063c25c47f442118/.github/workflows/check-by-name.yml#L31-L92 + # https://github.com/getsentry/sentry/issues/22432 + # https://github.com/getsentry/sentry/pull/22344 + # This step has to be in this file, + # because it's needed to determine which revision of the repository to fetch, + # and we can only use other files from the repository once it's fetched. + - id: merge-commit + name: Resolving the merge commit + env: + GH_TOKEN: ${{ github.token }} + run: | + # This checks for mergeability of a pull request as recommended in + # https://docs.github.com/en/rest/guides/using-the-rest-api-to-interact-with-your-git-database?apiVersion=2022-11-28#checking-mergeability-of-pull-requests + + # Retry the API query this many times + retryCount=3 + # Start with 5 seconds, but double every retry + retryInterval=5 + while true; do + echo "Checking whether the pull request can be merged" + prInfo=$(gh api \ + -H "Accept: application/vnd.github+json" \ + -H "X-GitHub-Api-Version: 2022-11-28" \ + /repos/"$GITHUB_REPOSITORY"/pulls/${{ github.event.pull_request.number }}) + mergeable=$(jq -r .mergeable <<< "$prInfo") + mergedSha=$(jq -r .merge_commit_sha <<< "$prInfo") + + if [[ "$mergeable" == "null" ]]; then + if (( retryCount == 0 )); then + echo "Not retrying anymore, probably GitHub is having internal issues" + exit 1 + else + (( retryCount -= 1 )) || true + + # null indicates that GitHub is still computing whether it's mergeable + # Wait a couple seconds before trying again + echo "GitHub is still computing whether this PR can be merged, waiting $retryInterval seconds before trying again ($retryCount retries left)" + sleep "$retryInterval" + + (( retryInterval *= 2 )) || true + fi + else + break + fi + done + + if [[ "$mergeable" == "true" ]]; then + echo "The PR can be merged, checking the merge commit $mergedSha" + else + echo "The PR cannot be merged, it has a merge conflict, cancelling the workflow.." + gh api \ + --method POST \ + -H "Accept: application/vnd.github+json" \ + -H "X-GitHub-Api-Version: 2022-11-28" \ + /repos/"$GITHUB_REPOSITORY"/actions/runs/"$GITHUB_RUN_ID"/cancel + sleep 60 + # If it's still not canceled after a minute, something probably went wrong, just exit + exit 1 + fi + echo "mergedSha=$mergedSha" >> "$GITHUB_ENV" - uses: actions/checkout@v4 + with: + # pull_request_target checks out the base branch by default + ref: ${{ steps.merge-commit.outputs.mergedSha }} + # Fetches the merge commit and its parents + fetch-depth: 2 - uses: andresz1/size-limit-action@v1 with: github_token: ${{ secrets.GITHUB_TOKEN }} From 10b96c90db809373dcc1f33baf4c3f28e3b1f8ae Mon Sep 17 00:00:00 2001 From: Bob Ippolito Date: Mon, 13 Jan 2025 20:56:36 -0800 Subject: [PATCH 5/7] temporarily also run on pull_request for testing the logic --- .github/workflows/size-limit.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/size-limit.yml b/.github/workflows/size-limit.yml index 5b8bef8bbc2..45456be8697 100644 --- a/.github/workflows/size-limit.yml +++ b/.github/workflows/size-limit.yml @@ -1,5 +1,8 @@ name: 'Bundles' on: + pull_request: + branches: + - main pull_request_target: branches: - main From fd207036c3c9164c9c81deee1eb004a7459cc546 Mon Sep 17 00:00:00 2001 From: Bob Ippolito Date: Mon, 13 Jan 2025 21:09:04 -0800 Subject: [PATCH 6/7] size-limit should measure production artifacts --- .github/workflows/size-limit.yml | 1 + .size-limit.js | 7 ++----- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/size-limit.yml b/.github/workflows/size-limit.yml index 45456be8697..f3b0198fe1e 100644 --- a/.github/workflows/size-limit.yml +++ b/.github/workflows/size-limit.yml @@ -83,3 +83,4 @@ jobs: - uses: andresz1/size-limit-action@v1 with: github_token: ${{ secrets.GITHUB_TOKEN }} + build_script: build-prod diff --git a/.size-limit.js b/.size-limit.js index 2061cdfaf00..7d6c634c20c 100644 --- a/.size-limit.js +++ b/.size-limit.js @@ -24,12 +24,9 @@ const path = require('node:path'); * Looks like: * * { - * lexical: 'packages/lexical/dist/index.js', - * '@lexical/rich-text': 'packages/lexical-rich-text/dist/index.js', + * lexical: 'packages/lexical/dist/Lexical.js', + * '@lexical/rich-text': 'packages/lexical-rich-text/dist/LexicalRichText.js', * } - * - * Currently this alias map points at the cjs version of the build product, - * as that is what was measured previously in #3600. */ const {packagesManager} = require('./scripts/shared/packagesManager'); const getAliasType = (type) => From 352775473ba9e0701b986fb7933d924782194b3c Mon Sep 17 00:00:00 2001 From: Bob Ippolito Date: Mon, 13 Jan 2025 21:20:31 -0800 Subject: [PATCH 7/7] remove test from size-limit action --- .github/workflows/size-limit.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/size-limit.yml b/.github/workflows/size-limit.yml index f3b0198fe1e..564e988baa9 100644 --- a/.github/workflows/size-limit.yml +++ b/.github/workflows/size-limit.yml @@ -1,8 +1,5 @@ name: 'Bundles' on: - pull_request: - branches: - - main pull_request_target: branches: - main