I have a basic Polymer frontend application. I am using ajax to retrieve data from the backend:
<iron-ajax id="getAjax"
auto
url="http://localhost:14039/InvoiceService/envelop/{{envelopId}}/invoices"
handle-as="json"
last-response="{{invoices}}">
The ajax call is successfully made at startup. When I use other iron-ajax components to make POST requests, I trigger
this.$.getAjax.generateRequest();
and it functions properly.
My question is, how can I set up a timer to automatically call this function? Essentially, I want to regularly "refresh" the page using iron-ajax. I came across some solutions on how to do it with JQuery, but I find myself getting confused with Polymer's properties, functions, internal functions, this.$, etc.