is there any way i can bypass the runtime check? this dynamic route has a generate static params and
is there any way i can bypass the runtime check? this dynamic route has a generate static params and will always only generate 3 different endpoints
/blog/[slug]) is it possible say to turn a certain page into static e.g. /blog/1 would it still count towards a function call? According to https://developers.cloudflare.com/pages/configuration/serving-pages/#route-matching "If an HTML file is found with a matching path to the current route requested, Pages will serve it. Pages will also redirect HTML pages to their extension-less counterparts: for instance, /contact.html will be redirected to /contact, and /about/index.html will be redirected to /about/."routes.json?/_next/static/* invokes the functions script even static pages in a next.js project are billable requests afaik. You can see this rule in a single deployment under functions (at the bottom). Provided you use next-on-pages.wrangler.toml i believe the maintainer has a PR for that https://github.com/cloudflare/next-on-pages/pull/648 that will allow it to to be used seamlessly, there is an earlier chat where he describes it in this channel, next dev not that i know of but may be possible, im a huge donkey so hope im not leading you down the wrong direction, even now im wondering if i actually did create the KV in wrangler, or if it didn't just automatically do that,@cloudflare/next-on-pages, it generates a worker that is deployed along with the static assets for your Pages project. That worker handles all incoming requests to your Next.js Pages projectnext server
wrangler.toml so that wrangler doesn’t pick it up
next dev you can use/blog/[slug]/blog/1routes.json/_next/static/*setupDevBindings({
persist: true,
bindings: {
DB: {
type: "d1",
id: "local-test-db",
databaseName: "coaching",
}
}
});https://github.com/cloudflare/next-on-pages/blob/main/internal-packages/next-dev/README.mdif (process.env.NODE_ENV === 'development') {
import('@cloudflare/next-on-pages/next-dev').then(({ setupDevBindings }) => {
setupDevBindings({
bindings: {
// Add here the Cloudflare Bindings you want to have available during local development,
// for more details on Bindings see: https://developers.cloudflare.com/pages/functions/bindings/)
//
// KV Example:
TESTKV: {
type: "kv",
id: "TESTKV",
},
},
});
})
}wrangler pages dev outdir