By default, @astrojs/cloudflare will generate a _routes.json file that lists all files from your dist/ folder and redirects from the _redirects file in the exclude array. This will enable Cloudflare to serve files and process static redirects without a function invocation. Creating a custom _routes.json will override this automatic optimization and, if not configured manually, cause function invocations that will count against the request limits of your Cloudflare plan.
We should add a note to Cloudflare adapter document since the default auto-generated _route.json file can easily exclude the limits and cause Cloudflare Pages deployment failed.
A example error log
Error: Failed to publish your Function. Got error: Error 8000057: Rules in `_routes.json` are over the 100 rule limit. Refer to https://cfl.re/3FsE4aF.
The limits on Cloudflare Pages Functions doc
Functions invocation routes have the following limits:
You must have at least one include rule.
You may have no more than 100 include/exclude rules combined.
Each rule may have no more than 100 characters.
We should add a note to Cloudflare adapter document since the default auto-generated
_route.jsonfile can easily exclude the limits and cause Cloudflare Pages deployment failed.A example error log
The limits on Cloudflare Pages Functions doc