Photo by Matt Artz on Unsplash

How to pass data between routed components in Angular

Ľudovít Hajzer
ableneo Technology
Published in
3 min readMar 22, 2019

--

In this article we will show how two unrelated components in Angular can pass data around.

There are several ways how Angular components can pass data around:

  • Using @Input and @Output
  • By injecting parent component through constructor or child components through @ViewChild, @ViewChildren, @ContentChild, @ContentChildren

--

--