Is there a reason cshtml is not popular

Firstly, I only recently tried my hand at creating with a razor in cshtml using Webmatrix, and I found much less time than creating aspx web forms. Accustomed to this, I can now do everything that I did in my aspx projects before, much faster and with much less code ...

Now I spent today on google search, etc. in companies using cshtml, what they use for etc., but I can not find a large selection of examples. Maybe I was just looking for the wrong place to display this question incorrectly, but I had the feeling that there is a reason that companies are still using aspx over cshtml.

I am going to start the project next month for a big client, and I can’t decide if he should take a step to create it this way (they need a special blog, login area, etc.). Any suggestions? The only other stack thread I found for discussion anyway was: Razor / CSHTML - Any benefit from what we have?

Thanks,

Adam

+6
source share
3 answers

Many of them are associated with ASP (classics), it was much longer and (depending on the size of the project), migration can entail too much cost.

There are also considerations such as:

  • What does current Internet staff know (what do they speak fluently?)
  • Which libraries (proprietary or others) are already ASP-dependent (including custom controls).
  • How much of an SEO hit are you planning to convert (some sites can mimic the classic suffixes of aspx pages by simply changing the behavior of routes, but actually use cshtml).
+5
source

Experienced ASP.NET developers have no compelling reason to switch from web forms or MVC to web pages (Razor). As a basis, it is designed to attract those who can find web forms or MVC too much learning curve. For example, from classic ASP or PHP.

I answer a lot of questions about the structure of web pages on ASP.NET forums, and I definitely saw an increase in the number of people trying to create a framework. As far as functionality and security are concerned, you have the entire ASP.NET infrastructure, so you can do something with web pages that you can do with MVC or Web Forms - it’s a lot easier.

The structure of web pages is not designed taking into account the test capabilities, and it may be more difficult for groups to organize, since a certain amount of server logic is embedded in the same file as HTML.

If you are a lonely developer and happy with the use of web pages, go for it.

+3
source

There have been many discussions on this topic. His fair opinions, the right tool for the right job. Please read the following opinions and answers:

Hope this helps

+1
source

Source: https://habr.com/ru/post/926134/


All Articles