[AngularJS] Re: Headless web driver with AngularJS

2014-05-16 Thread Alon Nisser
Hey Lee - I encountered two common problems with running phantomjs as test runner/ selenium browser: 1. phantomjs doesn't implement all ES5 features. most notable would be ".bind" if you are using ,bind in your code (and we had a lot of it) then phantomjs "out of the box" would fail to handle i

[AngularJS] Re: How to use two ng-app in same page

2013-12-27 Thread Alon Nisser
As written before in the threads, you don't need two apps in the same page. both modules can be part of the same app - Actually that's the best way to do this - a module (or module) for directives, module (or modules) for controllers, filters, etc you need to include all the js file in index.ht

[AngularJS] Re: Can we have our client side (AngularJs) code and Server Side (i.e Spring/Hibernate) code on two different servers on same LAN

2013-12-27 Thread Alon Nisser
Besides what Daniel said, you need to make sure that the angular app know how to approach the back end (usually REST api of somekind) - if your server framework provides an api in a specific port, you'll have to point your ajax calls to that endpoint/port. if your lan prevents this kind of comm

[AngularJS] How to unittest something that happens in run phase (rootScope event listening)

2013-12-30 Thread Alon Nisser
I have something that must be on rootScope (also suggestions are welcome) a listener on stateChangeError events that reroutes them for error handling. I can't find how can I access the run phase in my unit testing? to unittest the specific listeners? I'll appreciate help/suggestions - Thanks!

[AngularJS] Re: ptor undefined

2014-01-02 Thread Alon Nisser
how do you run the test? 1.my setup works without the "var protractor = require .." part, since running with protractor gives you the protractor object 2. why do you need ptor.driver? just finished a bunch load of protractor testing with no ptor.driver needed - just using ptor directly. On Wed

[AngularJS] Re: Looking for a thesis topic on angular/javascript application frameworks

2014-01-03 Thread Alon Nisser
I think a work on the different generation of javascript frameworks could be very interesting (where angular.js and ember,js are the "Next generation frameworks", correlating framework development to js specs (es3, es5 es6 etc) and advancing browsers capabilities and new api's (eg html5). thje

[AngularJS] Re: filtering ng-repeat by multiple select tag including multiple data type.

2014-01-21 Thread Alon Nisser
assuming the other ng-model is search.weapon wouldnt this work?: {{item.name}} Did you try it? On Saturday, January 18, 2014 12:19:31 PM UTC+2, Shunsuke Hakamata wrote: > > Hello, > > I want to filter list by this object. > > $scope.items = [ > {name: 'fire-gun', attribute: 'fire', armor: 'gu

[AngularJS] Re: ui-router, css...state-change

2014-01-21 Thread Alon Nisser
A plunker would be helpful On Sunday, January 19, 2014 7:31:21 PM UTC+2, Daniel Jansson wrote: > > I am using ui-router and I have an abstract landing-page with two subviews > - login and register. > The parent state has a ng-include for the header. Acss error occurs when I > am changing from >

[AngularJS] Re: ui-router, local storage, restangular, service kunundrum

2014-01-21 Thread Alon Nisser
Can you specify what is the exact problem with this approach? This approach is generally correct. But from looking at your code I think the check if isAuthentecated would fail since the service doesn't run the check. I think you should add a `setter` and `getter` methods to this service, enabli

[AngularJS] Re: Display "not found" page/redirect when routing to an item that doesn't exist

2014-02-01 Thread Alon Nisser
Hey ben, it depends.. You can handle this in a number of ways, but basically all boiles to this: 1. If the url was valid (using ng-router, ui-router, or whatever ) and the data comes from the server - check for the error response. if it was 404 then redirect to the 404 url with the related vie

[AngularJS] Re: Display "not found" page/redirect when routing to an item that doesn't exist

2014-02-01 Thread Alon Nisser
Hey ben, it depends.. You can handle this in a number of ways, but basically all boiles to this: 1. If the url was valid (using ng-router, ui-router, or whatever ) and the data comes from the server - check for the error response. if it was 404 then redirect to the 404 url with the related vie