Skip to main content

bud.proxy

bud.proxy is a method that configures a proxy server for your development environment. This is useful when you need to proxy requests to a backend server, such as a WordPress site.

If you only need to modify the URL of the proxy server you should consider using bud.setProxyUrl and bud.setPublicProxyUrl.

Usage

By default, bud.proxy will target http://0.0.0.0.

bud.config.ts
bud.proxy()
bud.proxy(true) // these are equivalent

The proxy can be disabled with false.

bud.proxy(false)

You may use a String to set the proxy target:

bud.config.ts
bud.proxy('https://example.test')

Or, a URL object:

bud.config.ts
bud.proxy(new URL('https://example.test'))