title: http calls in polymer component as compared to angularjs services
body: <p>I have one service which is being used by different webcomponents in my application. So i am thinking to create a webcomponent which will have my service and can be imported in my webcomponents wherever needed just as is done in angularjs.</p>
  
  <p><strong>In Angular</strong></p>
  
  <pre><code>app.service('myService', function () {
      this.hello = function () {
          return "Hello World";
      };
      this.getData= function() {
        return $http({
          method: 'JSON', 
          url: 'SomeURL'
        });
  }
  </code></pre>
  
  <p><strong>In Polymer</strong> </p>
  
  <pre><code>&lt;dom-module id="my-service"&gt;
      &lt;script&gt;
  
      var myService= new Object();
  
      myService.hello = function () {
          return "Hello World";
      };
  
      myService.getData= function() {
        //How to convert this part in polymer context or we need to use &lt;iron-ajax&gt; , if yes then how?
        });
      }
  &lt;/script&gt;
  </code></pre>
  
  <p></p>
  
  <p>Can anybody tell me what is the best way to achieve the same in Polymer.</p>
  
  <p>Any help will be highly appreciated !!</p>