Reputation: 3
In Webpack, I can configure allowed hosts with subdomain wildcard matching using the allowedHosts option like this:
allowedHosts: ['.host.com', 'host2.com']
This configuration allows:
However, I can't find an alternative to this feature in Vite. How can I achieve a similar setup for allowed hosts with subdomain wildcard matching in Vite?
I searched the Vite documentation but only found the 0.0.0.0 wildcard configuration, which is used to listen on all available network interfaces. However, this doesn't seem to address subdomain wildcard matching for allowed hosts.
Upvotes: 0
Views: 487
Reputation: 55634
You should be able to pass true
to allowedHosts
.
See the doc entry.
Upvotes: 0