angular2-swing
angular2-swing copied to clipboard
this.swingCards.first.getCard() is null
Hi, when using example code, I try to get the first or last card from stack, but it's null. Any ideas?
this.swingCards.first.getCard()
The swingCards.first is a SwingCardComponent with a valid elementRef and etc. Any ideas?
+1
Hi, when using example code, I try to get the first or last card from stack, but it's null. Any ideas?
this.swingCards.first.getCard()
The swingCards.first is a SwingCardComponent with a valid elementRef and etc. Any ideas?
I think this is what you need
const firstNativeElement = this.swingCards.first.getNativeElement(); this.swingStack.stack.getCard(firstNativeElement)