oscarvz
How to build for React + Vite + Cloudflare worker?
Correct, I didn't dive into React specifically - though the same concept applies here as the API is more or less the same. If you're stuck with the static
index.html
file, I'd suggest looking into https://vite.dev/guide/api-plugin.html#transformindexhtml15 replies
How to build for React + Vite + Cloudflare worker?
I answered in #cloudflare, didn't see this post. You're getting that error @Vikash as mentioned in my first reply. The Vite React plugin expects an HTML file - which isn't here, because you're rendering the HTML now upon request using Hono. You can't have both
15 replies
I want to return component to API response which contsin useState.
Hi, this is because your component is built on the server, but no JS is shipped to your browser to make the component interactive. I wrote this article that can help you out:
https://dev.to/fiberplane/step-by-step-guide-adding-client-side-logic-to-your-hono-app-14eh
5 replies