title: installed npm package but get "is not a function" error in browser
body: <p>I'm using <strong>Ionic 4</strong> and trying to use this lib: <a href="https://date-fns.org" rel="nofollow noreferrer">https://date-fns.org</a> to get a date string like <code>2019-11-01 07:23:22</code> to be displayed in human readable way.</p>
  
  <p>So I've installed the lib with:</p>
  
  <pre><code>npm install date-fns --save
  </code></pre>
  
  <p>Then in <code>mypage.ts</code> file</p>
  
  <pre><code>import { format, formatDistance, parseISO } from 'date-fns';
  </code></pre>
  
  <p>And then in <code>mypage.html</code> file</p>
  
  <pre><code>&lt;div class="date"&gt;{{ formatDistance(parseISO(h.created_at)) }}&lt;/div&gt;
  </code></pre>
  
  <p>So I'm getting this error in browser console:</p>
  
  <pre><code>ERROR TypeError: _co.parseISO is not a function
  </code></pre>
  
  <p>It says the function doesn't exists, but it's in the docs: <a href="https://date-fns.org/v2.6.0/docs/parseISO" rel="nofollow noreferrer">https://date-fns.org/v2.6.0/docs/parseISO</a></p>
  
  <p>Am I doing something wrong?</p>