title: TypeError: Cannot read property 'content' of undefined
body: <p>I have a config file throwing error when only building with AOT <code>ionic cordova build android --prod</code></p>
  
  <blockquote>
    <p>Error: ./src/config/.env.ts Module build failed: TypeError: Cannot
    read property 'content' of undefined at Object.optimizationLoader
    (/Users/yasir/myApp/mobile/node_modules/@ionic/app-scripts/dist/webpack/optimization-loader-impl.js:14:24)
    at Object.loader
    (/Users/yasir/myApp/mobile/node_modules/@ionic/app-scripts/dist/webpack/optimization-loader.js:5:32)
    @ ./src/providers/post-service.js 15:0-40 @
    ./src/app/app.module.ngfactory.js @ ./src/app/main.ts</p>
  </blockquote>
  
  <p>This is the content of the <code>.env.ts</code> file. The file is inside src <code>.src/config/.env.ts</code></p>
  
  <pre><code>export const config: any = {
     serverUrl: "http://0.0.0.0:3000"
  };
  </code></pre>