title: Angular access parent variable from child component
body: <p>How do I get a variable from the parent, from a child component?</p>
  
  <p>app.component</p>
  
  <pre><code>secret: string = '123'
  </code></pre>
  
  <p>child.component</p>
  
  <pre><code>@Input() secret;
  
  console.log(this.secret);
  =&gt; undefined
  </code></pre>
  
  <p>Every example only shows template binding, for example <code>[secret]="secret"</code></p>
  
  <p>How do I just access the parent component's data from the child component?</p>