我正在尝试将此轮播(https://github.com/sheikalthaf/ngu-carousel)与Angular 4一起使用,但我一直收到此错误。
在App模块和组件中进行了所有导入之后,我已将模板中的代码简化为此,但仍然不会消失错误。有什么想法吗?
LINE=$($SHUF <"$fileName" | tr ' \011' '\012' | head -n "$len" | tr '\n' ' ')
echo "$LINE"
以下是组件中的代码:
getting and picking the
and picking the daisies
picking the daisies when
the daisies when suddenly
daisies when suddenly a
答案 0 :(得分:0)
尝试添加这两个按钮,
<button NguCarouselPrev class='leftRs'><</button>
<button NguCarouselNext class='rightRs'>></button>
查看ngu-carousel.component.ts的源代码,在ngOnInit()中有几个对nativeElement
的引用。我会说以下很可能是导致问题的原因
其中this.next
和this.prev
由
@ContentChild(NguCarouselNextDirective, { read: ElementRef })
private next: ElementRef;
@ContentChild(NguCarouselPrevDirective, { read: ElementRef })
private prev: ElementRef;