hey, quick question - would it make more sense to set up D1 connection on the server side of a cloud

hey, quick question - would it make more sense to set up D1 connection on the server side of a cloudflare pages app or move all db interactions on the cloudflare functions side?
Was this page helpful?