boolean | import('cors').CorsOptionstrue>= 1.1.11Configure CORS options for the dev server or preview server, based on the cors middleware.
true:Enable CORS with default options.false:Disable CORS.object:Enable CORS with the specified options.Only enable CORS for the dev server:
Disable CORS:
The cors option can be an object, which is the same as the cors middleware options.
The default configuration is the equivalent of:
For example, use the origin option to configure the Access-Control-Allow-Origin header: