Hacker News new | past | comments | ask | show | jobs | submit login

I haven't used Angular yet. From it's description it seems to be geared for making single page apps. Or a app with a few pages because it's good a binding data to an interface.

Is this accurate? What is a good use case for Angular?




Taking the load off of your server, and making the user's PC/tablet do more work, as well as greatly simplifying the server code to focus on data flow, business logic and data integrity, rather than mixing in presentation and minor U/I workflow complications. Having much of what you give to the remote client be static/cacheable content, with minimal data such as JSON passed rather than ballooned out JSP/JSF (etc) templated HTML, helps bring down bandwidth requirements, as well as server processing.

Of course, now you have A LOT of event handling in a client app on top of your middleware / micro-services, but I feel it is a helpful separation of concerns.

I suppose in my case it helps that I would rather do more of the app in Javascript, and less in Java. YMMV, substantially - I'm pretty sure I have a minority view at work :-)

We are working on a rewrite of a largish app (for a small team, anyway) at work. We already have a second, alternate, client app for our back end for a pilot project that we can now easily tackle with the new architecture. There were very few changes required on the server, just an alternate login method to automate an initial connection to a third party app (which then runs our alternate U/I in a frame), rather than an interactive SSO form.

We have a "Few Pages App", rather than Single Page App. By design, we reload a small number of alternate pages after a longish task, just in case (e.g. - resource leaks, whether from our own mishandling, or some library) - not because of known issues, mind you, but just out of my own paranoia that I would rather plan to allow for minor errors rather than requiring perfection.


I have used Angular in multi-page application, using Angular as a better JQuery in Spring MVC application. This setup worked well combining the best of both frameworks. Angular provided two-way binding, rendering templates (in loop), dialog box interactions, better AJAX, etc. Angular based component libraries provided calendar controls, dynamic tables, etc. Spring took care of the routing pages, handling UI requests and returning JSON response from services.


I think we should not discount this style of building a web app. I've also had success with it.

You need to think hard about whether you really need a SPA for something complex, or whether you can go back to the server completely in some instances.


Did you use a templating engine at all?


I think you've basically got it.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: