From 94da48dd76cd710d4e99001499357d18a46dbefc Mon Sep 17 00:00:00 2001 From: Evan Vetere Date: Wed, 28 Oct 2026 13:01:58 -0400 Subject: [PATCH] ci: Fail on React and router versions Strapi rejects The admin build only warns on a React 19 or react-router-dom 7 bump, and .npmrc sets legacy-peer-deps so install accepts them, so CI passed upgrades Strapi 5.59 cannot run. Key features/changes: - Run npm ls on react, react-dom, react-router-dom and styled-components, which exits non-zero on a version outside Strapi's peer ranges - Hold react and react-dom below 19 and react-router-dom below 7 in Renovate until Strapi raises its ranges --- .github/workflows/ci.yml | 1 + renovate.json | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 577c098..b3c5a10 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,5 +26,6 @@ jobs: node-version-file: .nvmrc cache: npm - run: npm ci + - run: npm ls react react-dom react-router-dom styled-components - run: npm run lint - run: npm run build diff --git a/renovate.json b/renovate.json index 0b03488..9ea804c 100644 --- a/renovate.json +++ b/renovate.json @@ -2,5 +2,15 @@ "$schema": "https://docs.renovatebot.com/renovate-schema.json", "extends": [ "local>datum-cloud/.github:renovate-config" + ], + "packageRules": [ + { + "matchPackageNames": ["react", "react-dom"], + "allowedVersions": "<19" + }, + { + "matchPackageNames": ["react-router-dom"], + "allowedVersions": "<7" + } ] }