title: Fix EXIF orientation Angular 2
body: <p>How can I fix the EXIF orientation in Angular 2?
  I am loading an image from mobile and I need to fix the orientation. </p>
  
  <p>I have tried the solution for this post: <a href="https://stackoverflow.com/questions/37361770/component-inputs-by-reference">Component inputs by reference</a> 
  but FileReaderEvent type is not recognised by typescript, EXIF does not exist, and I can't access to the imageRotateDegrees, ImageExifRotation... properties.</p>
  
  <p>This is my code:</p>
  
  <p><code>imageChange(input){
       if (input.files.length &gt; 0) {
              var img = document.createElement("img");
              img.src = window.URL.createObjectURL(input.files[0]);
              // Create a FileReader
              var reader = new FileReader();
              var self = this;
              reader.onload = function (e: any) {
                      img.onload = function() {
                             var resizedImg = self.resize(img);
                             self.model.base64Image = resizedImg;
                             self.picture = resizedImg;
                      }
                      img.src = e.target.result;
              } 
              reader.readAsDataURL(input.files[0])
        }
  }</code></p>