CaelNCSU All American 7079 Posts user info edit post |
Has it caught on back east? Seems like a more robust Knockout, which I haven't heard mentioned in a couple of years.
http://angularjs.org/
It is a lot easier to keep the view logic in the view without rat holing on if this.model.prop make view css this class. Kind of forces into best practices. 1/30/2014 12:26:33 PM |
BigMan157 no u 103354 Posts user info edit post |
i'm not a fan of it, plus it fucks up any kind of SEO 1/30/2014 1:24:43 PM |
qntmfred retired 40722 Posts user info edit post |
i'll just repost myself
Quote : | "my team has been using it for the past 6 months or so. It's very powerful and i especially like directives, but some of the syntax is unnecessarily unintuitive/non-discoverable, the documentation is notoriously lacking, it's hard to find good sources of best practices and what you do find online you can't trust if it's > 3 months old
still, i like it best compared to the other MV* js frameworks i've used" |
]1/30/2014 2:20:31 PM |
CaelNCSU All American 7079 Posts user info edit post |
You can have SEO. We do. Kind of hacky how it works though. 1/30/2014 3:25:14 PM |
kiljadn All American 44690 Posts user info edit post |
I would think that they're inherently incompatible.... Angular is for building applications. Why would you want to SEO an app? 1/31/2014 6:20:30 PM |
CaelNCSU All American 7079 Posts user info edit post |
Our site has a public face and content that's a "web page" but has things, like a music player, that are like an app. Some of the features require login, but some are for anyone. The backend is not SEO'd and what the employees use to create content for the site and view statistics about the business.
I've never really thought about the distinction. Previously if it had a login, border layout, checkboxes and battleship grey it was an app and if it had frames and shitty fonts it was a web page. I guess now it's more related to what's public.
We use phantom and render whatever it is a crawler requests.
[Edited on January 31, 2014 at 6:41 PM. Reason : a] 1/31/2014 6:39:46 PM |
Netstorm All American 7547 Posts user info edit post |
I don't actually know much about the guts of AngularJS but I sling content about it a lot at my current job. Very interesting and a lot of people like it quite a bit--but there's always strong opponents floating around to. 1/31/2014 9:42:18 PM |
David0603 All American 12764 Posts user info edit post |
I've been using it to build an internal application for about six months now. Hated it the first three, but it's really growing on me now. Seems super easy to do DOM manipulation and work with json objects via ng-repeat and the other directives. I'm actually just writing my first directive from scratch this week. Pretty cool stuff. We also use lowdash and underscore. Very nice after coming from IBM where third party libraries were essentially banned from use. 2/18/2014 4:13:13 PM |
CaelNCSU All American 7079 Posts user info edit post |
Why are you using lodash and underscore? Don't they do the same thing?
I just refactored a bunch of garbage controller code into a directive and had the html people redo the whole site in 30 minutes. Great power it has. 2/18/2014 9:36:54 PM |
Sayer now with sarcasm 9841 Posts user info edit post |
I recently ran a talent acquisition project looking for Java web developers with strong Angular.JS experience here in Raleigh.
Not the easiest find. 2/19/2014 7:11:39 AM |
David0603 All American 12764 Posts user info edit post |
Haha ditto.
^^ We started out using underscore, but soon realized there were more benefits to using lowdash.
http://stackoverflow.com/questions/13789618/differences-between-lodash-and-underscore 2/19/2014 9:05:15 AM |
CaelNCSU All American 7079 Posts user info edit post |
I have been doing mostly functional programming for about 2-3 years. I have definitely lost some of the OO skills I once had, though I know all the underscore functions like the back of my hand and have my own library of mixins. I still find interviewing the trend is to ask more OO questions. As an interviewer a couple of years ago it wasn't common to find interviewees that were familiar with functional concepts. Same as the interviewee, once in an interview the the guy was puzzled how I solved something functionally. 2/20/2014 1:01:47 PM |
kiljadn All American 44690 Posts user info edit post |
Quote : | "I recently ran a talent acquisition project looking for Java web developers with strong Angular.JS experience here in Raleigh.
Not the easiest find." |
because you're looking for something that generally doesn't make sense to lump together
a developer with familiarity with either of those technologies would probably stay the hell away2/20/2014 9:19:23 PM |
David0603 All American 12764 Posts user info edit post |
I was hired to be the lead java developer for this project, but for the last four months I've pretty much been solely coding in angular and other js. 2/21/2014 9:14:36 AM |
CaelNCSU All American 7079 Posts user info edit post |
Why don't they go together? If you're a Java full stack dev then what's a good choice if not angular? 2/21/2014 9:50:53 AM |
David0603 All American 12764 Posts user info edit post |
I'm curious as well. I'd love it if all the developers on my team were full stack. 2/21/2014 10:13:12 AM |
Netstorm All American 7547 Posts user info edit post |
I mean that's seems like a weird combination to me but I'm not a developer. Just none of the Java developers I work with or talk to use AngularJS, even though I understand it's pretty hot right now. BUT that might be a biased lens because most of the Java developers I work with are older. 2/21/2014 2:44:48 PM |
David0603 All American 12764 Posts user info edit post |
Even before angular I was still using some jQuery in conjunction with Dojo. 2/21/2014 2:52:42 PM |
Netstorm All American 7547 Posts user info edit post |
I mean, it makes sense for them to learn/be using Angular but for some reason a few of them act like it's a trend/fad and I don't really agree. 2/21/2014 4:32:45 PM |
kiljadn All American 44690 Posts user info edit post |
That's because java devs tend to be curmudgeons.
From my perspective, they don't go together because UI work shouldn't be done in Java to begin with. What you end up with from a lot of the existant frameworks out there is JIT compiled things that end up spitting out less-than performant javascript anyway (stuff like GWT, GXT, SmartGWT, Vaadin)... which seems pretty fucking redundant to me from a UI perspective. I don't like the idea of compiling down to something when the thing you're compiling down to is pretty damned good on its own.
I think there's nothing wrong with java middle and backend layers, those make sense, especially when you're talking about building robust, multi-threaded, scalable systems. But in most java developers eyes, the case for full stack development is that it makes sense to maintain one language so as to not have to switch gears. At least, that seems to be the impression I've gotten over and over, whether it be right or not.
Keeping in mind that all of this hinges on the fact that lots of java developers aren't familiar with how rapidly the world of javascript development has improved in the past 4-5 years, so they're stuck thinking that java offers more structured and stable options than JS for UI development, which simply isnt the case anymore. 2/23/2014 3:15:42 PM |
CaelNCSU All American 7079 Posts user info edit post |
No one mentioned java compiling to JS. I was thinking the standard guy who works on back end and front end with the back end being JS and front end angular. I'm not aware of anyone in this thread meant any different.
Speaking of Java on the front end. Anyone met a JavaFX guy in real life? I met people in 2006 that still did swing, but haven't seen any other real front ends, other than GWT, since then.
[Edited on February 23, 2014 at 9:03 PM. Reason : A] 2/23/2014 8:58:07 PM |
David0603 All American 12764 Posts user info edit post |
You mean backend being java? 2/24/2014 11:37:26 AM |
CaelNCSU All American 7079 Posts user info edit post |
Yeah, fuck you iPad. 2/24/2014 1:02:42 PM |
David0603 All American 12764 Posts user info edit post |
Agreed. I don't think anyone was talking about doing the frontend in java either. 2/24/2014 1:08:29 PM |
kiljadn All American 44690 Posts user info edit post |
I suppose it's where you work then, because I see tons of enterprise front-end work being done in java locally.
Which is totally ass-fuck backwards. 2/26/2014 7:18:06 AM |
Noen All American 31346 Posts user info edit post |
^Yeah, I've seen spots of that too. But it's overwhelmingly the backend service platform these days.
Just started looking into Angular yesterday. I started building a web service with Phalcon a couple of months ago and got the REST API built for it (was going to do a device-first frontend). But then I realized I still needed a website too, for both administrative shit as well as a client.
The thought of authoring and maintaining two distinct services, one for the rest api, one for the website sucked. So did completely combining the two (aka making the rest api just an offshoot of the website). Angular seems like the right solution for this.
I can have two separate pieces (api service, website), both being on phalcon, but the website really just being a very thin shell on the server to manage authentication (and keep my api keys secret) and permissioned view handling. The Angular client can use auth success to call out to the rest service, so I don't have to rewrite or duplicate any of that code. And it should let me keep the two things isolated, so they can scale independently.
Thoughts? It seems to make sense so far, but I am just now implementing my api auth system. 2/27/2014 3:55:11 AM |
David0603 All American 12764 Posts user info edit post |
Makes sense. I'd also look into request interceptors if you haven't already http://djds4rce.wordpress.com/2013/08/13/understanding-angular-http-interceptors/ The request interceptor is relatively new to angular and much needed imho 2/27/2014 9:55:00 AM |
CaelNCSU All American 7079 Posts user info edit post |
Quote : | "The thought of authoring and maintaining two distinct services, one for the rest api, one for the website sucked. So did completely combining the two (aka making the rest api just an offshoot of the website). Angular seems like the right solution for this." |
When you say service, do you mean an Angular service or some backend end point? I'd make most of what you are talking about a resource, and encapsulate that in an Angular service that could be shared by the controllers. There may not be a need for the service and the controllers just use the resource. I usually start by writing the controller and use $http then break it out as needed into a formal angular resource.
You can use the interceptors for bearer tokens or any other auth.
[Edited on February 27, 2014 at 12:34 PM. Reason : a]2/27/2014 12:33:33 PM |
Noen All American 31346 Posts user info edit post |
backend. I need a backend rest service for my device apps, and a backend service for auth. I want to keep the REST service and the Website's backend service separate and isolated from one another. The website's backend will exist almost purely to handle auth and getting a token to access the REST service. From that point on, it will just be the client website with Angular talking directly to the REST service.
At least that's how I've got this planned out. Basically I can't get around having some thin-backend paired to Angular to keep private keys private and keep privileged data and views from being accessible. 2/28/2014 7:31:45 AM |