title: Inherit react components with mobx
body: <p>I have a component which inherits from a abstract class and uses mobx decorators like this:</p>
  
  <pre><code>@inject("matrixStore")
  @observer
  export default class DayRow&lt;T extends IAbstractRowProps = IAbstractRowProps&gt; extends AbstractRow&lt;T&gt; {
       // ...
  }
  </code></pre>
  
  <p>The render function itself lives in the AbstractRow component.</p>
  
  <p>I inherit from DayRow with another component:</p>
  
  <pre><code>@inject("matrixStore")
  @observer
  export default class DayFinderRow extends DayRow&lt;IDayFinderRowProps&gt; {
  }
  </code></pre>
  
  <p>But when I try to render <code>DayFinderRow</code> there is a warning from mobx:
  <code>Mobx observer: You are trying to use 'observer' on a component that already has 'inject'. Please apply 'observer' before applying 'inject'</code>. And wenn I debug the rendered component it says <code>inject-DayRow-with-matrixStore#0.render()</code> instead of the anticipated <code>DayFinderRow#0.render()</code></p>
  
  <p>When I remove the decorators from <code>DayFinderRow</code>, the warning is gone, but instead of a <code>DayFinderRow</code> component a <code>DayRow</code> gets rendered.</p>
  
  <p>I need the decorators on both components, since I render both, but want to derive DayFinderRow from the DayRow, because I only need to change the behaviour of one function.</p>
  
  <p>Is this possible with mobx?</p>