title: (Typescript) Import json into Angular 4 project
body: <p>I have a json file of translations that I want to use in my angular 4 project. The file is also used in php which is why it needs to be stored as json rather than as a js module.</p>
  
  <p>It has this structure</p>
  
  <pre><code>export interface IDictionary {
      amsterdamCenter: number[];
      amsterdamBounds: Array&lt;number[]&gt;;
      prices: Price[];
      cuisines: Object;
      areas: Object;
  }
  </code></pre>
  
  <p>Following <a href="https://hackernoon.com/import-json-into-typescript-8d465beded79" rel="nofollow noreferrer">https://hackernoon.com/import-json-into-typescript-8d465beded79</a> I have changed typings.d.ts to read</p>
  
  <pre><code>/* SystemJS module definition */
  declare var module: NodeModule;
  interface NodeModule {
    id: string;
  }
  
  declare module "*.json" {
    const value: any;
    export default value;
  }
  </code></pre>
  
  <p>Now I have an error with </p>
  
  <pre><code>import * as dictionary from './dictionary.json';
  
  export const Dictionary: IDictionary = dictionary;
  </code></pre>
  
  <blockquote>
    <p>[ts] Type 'typeof "<em>.json"' is not assignable to type 'IDictionary'. Property 'amsterdamCenter' is missing in type 'typeof "</em>.json"'.</p>
  </blockquote>
  
  <p>However</p>
  
  <pre><code>export const Dictionary: any = dictionary;
  </code></pre>
  
  <p>does work. I'm hoping there is an incantation of TS that will permit me to import typescript using my interfaces</p>