pawtang
pawtang
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
First was server. Irrelevant
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
"scripts": { "dev": "react-scripts start", "start": "serve build -s -n -L -p $PORT", "build": "react-scripts build", "test": "react-scripts test", "eject": "react-scripts eject" },
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
"scripts": { "test": "echo "Error: no test specified" && exit 1", "start": "node index.js", "run dev": "nodemon index.js" },
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
Nice, I'm online, no web socket errors, client and server are happy. thanks.
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
vs global
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
Oh, serve should be installed in client folder yeah? or does it matter
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
I'll give it a shot now
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
Awesome 🙂 thanks again for the support.
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
Yes
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
Bear with me I'm honestly quite stupid. I don't know if it counts as a SPA if it's technically rendering all of this content in the single html page "index.html" or if the inclusion of a router that builds URLs dynamically means its not a SPA
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
const App = () => {
return (
<>
<ToastManager />
{/* <ToastManager toastStack={toastStack} /> */}
<Routes>
<Route path="/" element={<Landing />} />
<Route path="about" element={<About />} />
<Route path="contact" element={<Contact />} />
<Route path="signup" element={<Signup />} />
<Route path="login" element={<Login />} />
<Route path="dashboard" element={<Dashboard />} />
<Route path="suppliers" element={<ManagerSuppliers />} />
<Route path="materials" element={<ManagerMaterials />} />
<Route path="transactions" element={<ManagerTransactions />} />
</Routes>
</>
);
};

ReactDOM.render(
<BrowserRouter>
<ToastProvider>
<UserProvider>
<App />
</UserProvider>
</ToastProvider>
</BrowserRouter>,
document.getElementById("root")
);
const App = () => {
return (
<>
<ToastManager />
{/* <ToastManager toastStack={toastStack} /> */}
<Routes>
<Route path="/" element={<Landing />} />
<Route path="about" element={<About />} />
<Route path="contact" element={<Contact />} />
<Route path="signup" element={<Signup />} />
<Route path="login" element={<Login />} />
<Route path="dashboard" element={<Dashboard />} />
<Route path="suppliers" element={<ManagerSuppliers />} />
<Route path="materials" element={<ManagerMaterials />} />
<Route path="transactions" element={<ManagerTransactions />} />
</Routes>
</>
);
};

ReactDOM.render(
<BrowserRouter>
<ToastProvider>
<UserProvider>
<App />
</UserProvider>
</ToastProvider>
</BrowserRouter>,
document.getElementById("root")
);
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
index.html is in the client side and only contains some metadata and the root for injecting the react build
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
I don't think so?
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
What's bad here
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
I'm all ears
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
server scripts: "scripts": { "test": "echo "Error: no test specified" && exit 1", "start": "nodemon index.js &", "run dev": "nodemon index.js" },
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
Yessir
37 replies
RRailway
Created by pawtang on 5/24/2023 in #✋|help
PERN Application with React Router -- WebSocket connection to 'xxx' failed:
3bf7a56e-38fc-403a-92fa-0dcccfe80e97
37 replies
RRailway
Created by pawtang on 5/22/2023 in #✋|help
503/Cors error deploying PERN App for first time
Ah I fooled myself, I thought the server was ok since the build worked and client was up. This looks promising. Thanks
6 replies