Problem with deploying to GitHub Pages / react router configuration

ok, I’ll experiment with this. Thanks marcel!

by user 216692838757433347

it worked! :MarioHype:

by user 216692838757433347

Changed the channel name: Problem with deploying to GitHub Pages / react router configuration

Update: Only the root page worked after all, but I resolved this by using a HashRouter instead of a BrowserRouter. For this I had to change the routes back to how they were originally, and the URLs have to have hashtags now like this: https://ts-programming.github.io/needle-portfolio-react/#/pentago

by user 216692838757433347

this is my App.tsx now```ts
import React from ā€˜react’;
//import { BrowserRouter as Router, Route, Routes } from ā€˜react-router-dom’;
import { HashRouter as Router, Routes, Route } from ā€˜react-router-dom’;
import Home from ā€˜./Home/home’;
import Pentago from ā€˜./GamePages/pentago’;
import MakingTheSite from ā€˜./GamePages/makingTheSite’;

import {
ChakraProvider,
extendTheme,
} from ā€˜@chakra-ui/react’;

function App() {

const theme = extendTheme({
config: {
initialColorMode: ā€˜dark’,
useSystemColorMode: false,
},
styles: {
global: {
body: {
bg: ā€˜#181414’, // Set the background color for dark mode
color: ā€˜white’, // Set the text color for dark mode
},
},
},
});

return (



<Route path=ā€œ/ā€ element={} />
<Route path=ā€œ/pentagoā€ element={} />
<Route path=ā€œ/making-the-siteā€ element={} />



);

}

export default App;


*by user 216692838757433347*

Everything is working as intended now except for one bug. When hitting back on the browser to to return to the home page, the NeedleEngine component doesn’t work. It will show the loading screen like normal, but after it ā€œloadsā€ its just blank instead of properly showing the scene like when the homepage is accessed directly by URL. Not sure if this should issue should be discussed in a new thread or not

by user 216692838757433347

That’s a bug which we just fixed in the latest release i think :slightly_smiling_face: