fix(excalidraw): use import map to force React 18.3.1 for ALL modules including Excalidraw internals
CI / lint (push) Failing after 10s
CI / test (push) Has been skipped
CI / build (push) Has been skipped
CI / e2e (push) Has been skipped
CI / security (push) Successful in 23s
Desktop Build / build-windows (push) Has been cancelled
Desktop Build / build-linux (push) Has been cancelled

This commit is contained in:
2026-07-29 11:41:30 -04:00
parent 7d8fa18201
commit 8c665fb568
6 changed files with 104 additions and 13 deletions
+3 -3
View File
@@ -19,7 +19,7 @@ function add(msg, cls='') {
add('--- Step 1: Testing esm.sh connectivity ---');
try {
const res = await fetch('https://esm.sh/react@18', { method: 'HEAD' });
const res = await fetch('https://esm.sh/react@18.3.1', { method: 'HEAD' });
add(`✓ esm.sh reachable (HTTP ${res.status})`, 'pass');
} catch(e) {
add(`✗ esm.sh unreachable: ${e.message}`, 'fail');
@@ -27,7 +27,7 @@ try {
add('\n--- Step 2: Importing React ---');
try {
const React = await import('https://esm.sh/react@18');
const React = await import('https://esm.sh/react@18.3.1');
add(`✓ React imported (keys: ${Object.keys(React.default||React).slice(0,5).join(',')})`, 'pass');
window.React = React;
} catch(e) {
@@ -36,7 +36,7 @@ try {
add('\n--- Step 3: Importing ReactDOM ---');
try {
const ReactDOM = await import('https://esm.sh/react-dom@18');
const ReactDOM = await import('https://esm.sh/react-dom@18.3.1');
add(`✓ ReactDOM imported`, 'pass');
window.ReactDOM = ReactDOM;
} catch(e) {