From c5aabe8a69e0dd7ee91df59976826345c4522b87 Mon Sep 17 00:00:00 2001 From: Nyi Nyi Lwin <53917354+mdynnl@users.noreply.github.com> Date: Thu, 15 Aug 2024 02:55:16 +0700 Subject: [PATCH] use esm.sh ?external query --- packages/solid-repl/src/components/repl.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/solid-repl/src/components/repl.tsx b/packages/solid-repl/src/components/repl.tsx index 0c0a697..b2ef637 100644 --- a/packages/solid-repl/src/components/repl.tsx +++ b/packages/solid-repl/src/components/repl.tsx @@ -130,6 +130,9 @@ export const Repl: ReplProps = (props) => { if (!(file in compiled) && currentMap[file] === `https://esm.sh/${file}`) { delete currentMap[file]; } + if (file.split('/')[0] !== 'solid-js' && currentMap[file] === `https://esm.sh/${file}`) { + currentMap[file] = `https://esm.sh/${file}?external=solid-js`; + } } for (const file in compiled) { if (!(file in currentMap) && !file.startsWith('./')) {