Bind KV for Pages on Deploy

When I deploy my KV, especially as a new project through the Cloudflare Pages setup, is there a way to automatically bind a specific KV from the start instead of having to do it through the Functions Settings after it is created?
8 Replies
Chaika
Chaika12mo ago
Not through the dashboard, could try scripting it via the API if you do it a lot
jjjrmy
jjjrmyOP12mo ago
I mean in my repo like can I still us a wrangler.toml file
Chaika
Chaika12mo ago
No, Pages doesn't use that*. Everything has to be set in the dashboard * For local dev (Wrangler pages dev),it may pick it up and use it for some things, but never for deployment/deployed pages
jjjrmy
jjjrmyOP12mo ago
okay so if I'm doing pages through the dashboard, I have just do remember to do it manually if I were to do it via CLI and deploy that way can I use the Wrangler file?
Chaika
Chaika12mo ago
no
jjjrmy
jjjrmyOP12mo ago
oh so Pages just doesn't use the Wrangler config files
Chaika
Chaika12mo ago
Correct, except in local dev for some things Wrangler config files are for Cloudflare Workers
jjjrmy
jjjrmyOP12mo ago
gotcha kinda annoying but no biggie
Want results from more Discord servers?
Add your server