Reputation: 11
I have made a react project with vite, and it works correctly. Now I want to make a desktop appliction from react project using wails framework of golang, I have built the application but when I run it using wails dev
hundreds of errors appear like these two errors:
DEB | [ExternalAssetHandler] Loading 'http://127.0.0.1:5173/src/interfaces/admin/blocks/functions/editBlock.js'
DEB | [AssetHandler] Handling request '/src/interfaces/admin/blocks/functions/deleteBlock.js' (file='src/interfaces/admin
/blocks/functions/deleteBlock.js')
So what may be the wrong with that :( ???? should I edit my react code in some way to run with wails ??
Upvotes: 1
Views: 161
Reputation: 41
Those are just debug (DEB) logs, if you wanna remove them you should change the log level to something like error https://wails.io/docs/reference/runtime/log/#logsetloglevel
watch out if using react-router-dom and use
<HashRouter basename={yourBaseName} />
instead of<BrowserRouter />
as the wails docs suggest (also don't do hrefs and redirects withoutuseNavigate
or<Navigate />
from the react-router-dom, otherwise you'll actually search for other routes and resources instead of "/", thus losing the bindings reference towindow.go
)
Upvotes: 1