Getting 308 permanent redirect using Wrangler pages dev

For Workes & Pages, what is the name of the domain?

notdeployedbutthisfieldisrequired.com

What is the isssue or error you’re encountering

I’m building a site which is 90% static but then have a React SPA running in the /app directory. I set up the _redirects to proxy requests from /app/* to /app.html with a status code of 200. However after I build the site and run npx wrangler pages dev ./build I’m getting 308 permanent redirect on all of those routes and the url reverts to just /app so there’s no path for my SPA to match. Am I doing something wrong?

What steps have you taken to resolve the issue?

Followed the docs Redirects · Cloudflare Pages docs to proxy all /app/* to /app.html

It does say that if there’s no top-level 404.html pages that Cloudflare assumes you’re deploying an SPA and automatically proxies /* to /index.html. But I believe what I tried should be working for a “nested” SPA.

What are the steps to reproduce the issue?

Create a static website with an SPA in a directory and try to proxy all requests to the base url of that directory.

Tried deploying to Cloudflare Pages and getting the same issue. It is redirecting all /app/* to /app.html with a 308 permanent redirect instead of proxying it with a 200 ok.

Anybody know how to get it working correctly?

How does cloudflare configure redirects for an SPA like they do automatically when no top level 404.html exists?

Got it to work using Transform URL Rewrite Rules from this thread Cloudflare pages proxy redirect not working? this thread is over a year old and states that using the _redirects file is expected to be supported soon.

But a over a year later and the transform rules are required?