fix(cors): load /devv-app.js via runtime injection to avoid vite build resolution
This commit is contained in:
parent
ba92de04f2
commit
5a111a3d3e
1 changed files with 9 additions and 2 deletions
11
index.html
11
index.html
|
|
@ -9,8 +9,15 @@
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="root"></div>
|
<div id="root"></div>
|
||||||
<!-- IMPORTANT: Keep this script for advanced features; proxied via server to avoid CORS -->
|
<!-- IMPORTANT: Load external tool via runtime injection to avoid Vite resolving at build time -->
|
||||||
<script src="/devv-app.js" type="module"></script>
|
<script>
|
||||||
|
(function() {
|
||||||
|
var s = document.createElement('script');
|
||||||
|
s.type = 'module';
|
||||||
|
s.src = '/devv-app.js';
|
||||||
|
document.head.appendChild(s);
|
||||||
|
})();
|
||||||
|
</script>
|
||||||
<script type="module" src="/src/main.tsx"></script>
|
<script type="module" src="/src/main.tsx"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue