0

I am experimenting with the AngularJS approach for PhoneJS. So far I am really enjoying both frameworks.

Current issues:

  • Using a dx-gallery or dx-list with a datasource and a template will cause the initial un-bound template to be rendered when the view is navigated.

I found this out once I started using the dx-gallery widget and specifying a template. The console will show a network request for the initial template (not bound) being requested.

Code

<div dx-gallery="{ dataSource: imagesDataSource, height:'60%' }">
<div data-options="dxTemplate: { name: 'item' }">
    <img src="http://somehostingcompany.com/{{public_id}}.jpg">
</div>

Question: How can I not have the initial HTML template rendered when using a PhoneJS dx-gallery widget and a template?

Travis
  • 3
  • 3

1 Answers1

0

Use ns-src binding instead of specifing src directly:

<img ng-src="http://somehostingcompany.com/{{public_id}}.jpg" />

Check out link https://docs.angularjs.org/api/ng/directive/ngSrc

tabalin
  • 2,303
  • 1
  • 15
  • 27
  • Thanks. I can't remember if I tried this or not, but I will give it a shot and let you know. – Travis Apr 28 '14 at 18:13