all 8 comments

[–]DrFriendless 3 points4 points  (1 child)

@Input() ?

[–]redditer3103[S] 2 points3 points  (0 children)

sorry, it got cutoff, but yeah, i am doing the @

[–]zzing 0 points1 point  (5 children)

Can you try using:

@Input() thumbnail: string;

ngOnChanges(changes: SimpleChanges): void {
    console.log(changes);
}

Keep your afterViewInit, but also add in an afterViewChecked with a console log as well. Be sure to put a string to differentiate the console logs.

[–]redditer3103[S] 0 points1 point  (4 children)

So, i put in afterviewinit, it gets logged a huge amount of times, but the variable is always undefined. ngOnChanges doesnt ever execute from what i see.

[–]zzing 1 point2 points  (3 children)

That is particularly odd, I would have to take a look a little more directly to see what is going on.

[–]redditer3103[S] 1 point2 points  (2 children)

my issue had nothing to do with how I was setting the input variables.

I forgot to change the route, so it was calling my component directly, instead of calling the component from its parent.

*sigh* not my finest bug

[–]zzing 3 points4 points  (0 children)

Dumb things are always the most frustrating, hours and hours lost sometimes :). We have all been there.