Typings incorrect for CommonServerOptions https
, should be | boolean
#17580
Labels
contribution welcome
documentation
Improvements or additions to documentation
good first issue
Good for newcomers
Describe the bug
setting preview> https: true in vite.config
![image](https://github.com/vitejs/vite/as
sets/1592820/ba15f4d5-8ee8-4926-be81-9eeab3eec984)
Reproduction
.
Steps to reproduce
Create a vite config with
preview: { https: true}
Get compilation error:
Type 'true' has no properties in common with type 'ServerOptions'.ts(2559)
I thikn this line
vite/packages/vite/src/node/http.ts
Line 31 in 24c799b
needs changing to
https?: HttpsServerOptions | boolean
to satisfy the docs at https://vitejs.dev/config/preview-options#preview-https
System Info
Used Package Manager
pnpm
Logs
No response
Validations
The text was updated successfully, but these errors were encountered: