An intersection combines existing types meaning all the types on both object are present. You cannot use the type of the declared variable to define testProps
if its a union of multiple types, as when you set the default value you bind it to a particular type.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.