title: How do I make Typescript pick up a declaration file?
body: <p>My file <code>src/auth/ManagementAPI.ts</code> uses Auth0. I need to use my own declaration file and have created <code>src/@types/auth0.d.ts</code>.</p>
  
  <p>However, when I run <code>ts-node</code>, I'm getting this error:</p>
  
  <pre><code>TSError: ⨯ Unable to compile TypeScript:
  auth/ManagementAPI.ts(1,69): error TS7016: Could not find a declaration file for module 'auth0'. '/Users/danrumney/WebstormProjects/ohana/node_modules/auth0/src/index.js' implicitly has an 'any' type.
    Try `npm install @types/auth0` if it exists or add a new declaration (.d.ts) file containing `declare module 'auth0';
  </code></pre>
  
  <p>I've updated my <code>tsconfig.json</code> file to include:</p>
  
  <pre><code>"typeRoots": [
      "./node_modules/@types",
      "./src/@types"
  ]
  </code></pre>
  
  <p>My declaration file is like this:</p>
  
  <pre><code>declare module 'auth0' {
    /*...*/
  }
  </code></pre>
  
  <p>Why is this declaration not being picked up?</p>
  
  <p>I've created an example repository here: <a href="https://bitbucket.org/ohanapediatrics/so-demo/src/master/" rel="noreferrer">https://bitbucket.org/ohanapediatrics/so-demo/src/master/</a></p>