worldzhao / vue-nice-modal

Vue Nice Modal is a utility library that converts Vue.js modal components into a Promise-based API, making it easy to integrate with other UI libraries. Inspired by @ebay/nice-modal-react and vant.
https://worldzhao.github.io/vue-nice-modal/
41 stars 4 forks source link

typescript类型问题,关于prop如果为可选对象会丢失类型为unknown #11

Open zogwosh opened 5 months ago

zogwosh commented 5 months ago

举个例子

interface IProps extends INiceModalHandlers<number> {
  visible: boolean;
 model?:{
key?:string
key2?:string
key3?:string
}
}

会丢失model的类型