refer to local paths

This commit is contained in:
Corwin 2023-07-05 21:47:36 +01:00
parent cb68d8c695
commit 7665135329
No known key found for this signature in database
3 changed files with 4 additions and 3 deletions

View file

@ -1,6 +1,7 @@
{ {
"name": "website", "name": "website",
"version": "0.1.0", "version": "0.1.0",
"homepage": "./",
"private": true, "private": true,
"dependencies": { "dependencies": {
"@testing-library/jest-dom": "^5.16.5", "@testing-library/jest-dom": "^5.16.5",
@ -48,4 +49,4 @@
"@types/styled-components": "^5.1.26", "@types/styled-components": "^5.1.26",
"prettier": "2.8.8" "prettier": "2.8.8"
} }
} }

View file

@ -85,7 +85,7 @@ function App() {
{isPlaying ? ( {isPlaying ? (
<Mgba <Mgba
ref={mgbaRef} ref={mgbaRef}
gameUrl="/game.gba" gameUrl="./game.gba"
volume={volume} volume={volume}
controls={bindings.Actual} controls={bindings.Actual}
paused={paused} paused={paused}

View file

@ -73,7 +73,7 @@ export const Mgba = forwardRef<MgbaHandle, MgbaProps>(
canvas: canvas.current, canvas: canvas.current,
locateFile: (file: string) => { locateFile: (file: string) => {
if (file === "mgba.wasm") { if (file === "mgba.wasm") {
return "/vendor/mgba.wasm"; return "./vendor/mgba.wasm";
} }
return file; return file;
}, },