O
O
oyaebunterkrah2014-03-08 14:26:52
Angular
oyaebunterkrah, 2014-03-08 14:26:52

With what to use AngularJS: with ASP.NET, ASP.NET MVC or pure .NET?

Good afternoon.
I recently came across AngularJS .
I want to get to know him better.
Friends who use it say that you can basically get by with pure .NET , there is no need to create an ASP.NET or ASP.NET MVC project.
Like, using AngularJS , you can get by with SOA (service-oriented architecture) on the server side .
Those. AngularJS will take over the entire client side , and only data is required from the server.
Can you speak for and against ?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
K
Kokcuk, 2014-03-08
@oyaebunterkrah

Recently the same question arose - creating a backend for a js application, in the end result there is no difference between wcf and mvc, but they chose mvc, because mvc is a ready-made rest service out of the box that gives the js page itself without any problems, serializes everything as it should through api methods, and has no performance issues. In wcf, to set it up like that, you have to sweat.

B
Bob Smith, 2014-05-26
@bob_smith

Just finished a project on ASP.NET MVC + WebApi + AngularJS. It turned out very cool. The logic is this: MVC controllers return only a clean view with markup for AngularJS, which accesses WebApi, receives data in JSON, and maps onto the view. And when the data changes, it sends them in JSON back to WebApi.
Pluses:
1) A clear division into layers of logic. WebApi controllers are covered by unit tests.
2) A clear separation of the work of client and server developers. Only interfaces of models reach the developer of the client code, moreover, they are already guaranteed to work, because verified by tests.
3) External services (with which we integrate or, in the future, a mobile application) are integrated with the same api that the site itself works with.
Minuses:
1) It is required to add a decent amount of client logic to correctly display validation errors.
2) Large pages (and in our particular project, several views with different api-controllers were displayed on one page) take a long time to load: first an empty page is displayed, then the first part, after a couple of seconds another, etc. But this is more of an optimization issue than AngularJS

W
w1ld, 2014-04-07
@w1ld

You can use the ASP.NET Web API. It's some kind of variant between WCF and MVC. It is sharpened for http and it is stated (did not try) that it starts without IIS. If you do not need to create VIEW on the server at all, then, apparently, it will suit you.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question