Hi,
I'm evaluating AngularJS for my project which is a web/mobile GIS app that will be using OpenLayers. Currently I'm struggling to initialize OpenLayer from the Angular-driven code. It seems "normal" javascript is not being called called (e.g. by onload event for example). Is there a way to call a function from a third-party library in Angular?
--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To view this discussion on the web visit https://groups.google.com/d/msg/angular/-/YRBGs-KE3EsJ.
To post to this group, send email to ang...@googlegroups.com.
To unsubscribe from this group, send email to angular+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/angular?hl=en.
Have you tried running it from a controller?
On 26 July 2012 08:23, <obura...@gmail.com> wrote:
Hi,
I'm evaluating AngularJS for my project which is a web/mobile GIS app that will be using OpenLayers. Currently I'm struggling to initialize OpenLayer from the Angular-driven code. It seems "normal" javascript is not being called called (e.g. by onload event for example). Is there a way to call a function from a third-party library in Angular?
--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To view this discussion on the web visit https://groups.google.com/d/msg/angular/-/YRBGs-KE3EsJ.
To post to this group, send email to ang...@googlegroups.com.
To unsubscribe from this group, send email to angular+unsubscribe@googlegroups.com.
Are you sure it is not being called. I suspect it is but that the library is relying on the scope being bound to some element before the call.
You could try putting the call to initMap in a $timeout to ensure the digest has updated everything.
Pete
...from my mobile.
To view this discussion on the web visit https://groups.google.com/d/msg/angular/-/rPVS72444NoJ.
To post to this group, send email to ang...@googlegroups.com.
To unsubscribe from this group, send email to angular+u...@googlegroups.com.