jman
jman
Explore posts from servers
CDCloudflare Developers
Created by jman on 12/15/2024 in #workers-help
RPC of a Service Binding / DO: Adding middleware?
I don't see any references in the docs so I assume the answer is no, but I'm wondering if it's possible to add middleware in any way to Durable Object RPC classes or Service Bindings? I could envision a potential userland solution, but I'm curious if there is something that already exists?
1 replies
CDCloudflare Developers
Created by jman on 4/7/2024 in #pages-help
Specifying a `-- <command>` or `--proxy` is deprecated and will be removed
Recently noticed this warning when running wrangler pages dev -- vite:
[WARNING] Specifying a `-- <command>` or `--proxy` is deprecated and will be removed in a future version of Wrangler.

Build your application to a directory and run the `wrangler pages dev <directory>` instead.
This results in a more faithful emulation of production behavior.
[WARNING] Specifying a `-- <command>` or `--proxy` is deprecated and will be removed in a future version of Wrangler.

Build your application to a directory and run the `wrangler pages dev <directory>` instead.
This results in a more faithful emulation of production behavior.
I'm curious what the suggestion is for users of vite or similar framework where there is no directory in dev mode?
3 replies
CDCloudflare Developers
Created by jman on 3/15/2024 in #pages-help
Point to remote r2 bucket when running pages dev locally?
Is there any way to point a binding to a remote r2 bucket when running pages dev locally? From the docs on the --r2=BINDING_NAME flag, it seems to only support a local bucket?
2 replies
CDCloudflare Developers
Created by jman on 3/5/2024 in #pages-help
Preview branch, custom domain not supported
When adding a custom domain for a preview branch using external DNS, this page states that custom domains are not supported for external DNS. https://developers.cloudflare.com/pages/how-to/custom-branch-aliases/ Why does this limitation exist? Are there any ways to work around this functionality?
9 replies
TtRPC
Created by jman on 2/29/2024 in #❓-help
Is there any way to temporarily disable mutations?
My goal is to move into a read-only mode temporarily. I'm thinking anything could be fine as a short term solution. 1. Throw an explicit error when mutations try to be called 2. Procedure not found error 3. Stop support POST requests?
2 replies
CDCloudflare Developers
Created by jman on 12/28/2023 in #pages-help
Ignore paths in pages `functions` directory
Are there any prefixes that will allow me to ignore files in the functions directory, so I can locate my non-route logic adjacent to my routes? Other frameworks often use an underscore prefix for instance If not, is there a way to specify multiple directories for wrangler to watch during wrangler pages dev? Putting my server code in ./server doesn't trigger auto-refreshes...
1 replies
CDCloudflare Developers
Created by jman on 7/30/2023 in #workers-help
See logs when using unstable_dev?
When using unstable_dev, I can't seem to find any docs on how to see / inspect logs or errors coming from the worker or durable objects. How can I see the logs?
3 replies
CDCloudflare Developers
Created by jman on 6/30/2023 in #workers-help
Determine if built by wrangler dev or wrangler deploy
I have a worker which when running locally will proxy to a Vite server, but when deployed will be a Workers Site using kvAssetHandler. Is there any default way to determine which it was built for? Or do I need to mess with .dev.vars?
1 replies