Angular Component Communication, Day 2

In my last article, we looked at how we can pass data between components using the @Input and @Output directives and using event emitters. Today, let’s see the other two methods, @ViewChild and data services, can be used to pass data between components.
Let’s break up the article into two sections. First, we will look at ViewChild, then move on to data services.