如何将PerfectScrollbarComponent (ngx-perfect-scrollbar)选择器是'perfect-scrollbar‘组件动态添加到Angular 5组件?
提前谢谢你。
发布于 2018-09-11 20:18:46
在你的template.html中
<perfect-scrollbar #perfectscroll>...</perfect-scrollbar>在你的component.ts中
import { PerfectScrollbarComponent } from 'ngx-perfect-scrollbar';
...
@ViewChild('perfectscroll') ps: PerfectScrollbarComponent;
...
this.ps.directiveRef.scrollToBottom();https://stackoverflow.com/questions/50463251
复制相似问题