ant design vue select随页面滚动

使用ant design vue的select组件时 下拉菜单选项随body滚动而滚动

解决方案

:getPopupContainer="()=>document.getElementById('category-select')"
:dropdownStyle="{zIndex:10,TextAlign:'left!important'}"
父级元素中找一个div 设置id=category-select (试了好几个)

 data() {
      var doc
      if (process.browser) {
        doc = document
      }
      return {
        document:doc,
    }    
}
原文地址:https://www.cnblogs.com/icelan/p/11423179.html