Ayende @ Rahien

Hi!
My name is Ayende Rahien
Founder of Hibernating Rhinos LTD and RavenDB.
You can reach me by phone or email:

ayende@ayende.com

+972 52-548-6969

@

Posts: 5,947 | Comments: 44,540

filter by tags archive

Comments

Graham

Buggrit!

Barry Dahlberg

Gee if you had those all in custom controls you'd be able to make one change to fix all your labels so they are associated with their text boxes...

<labelPass

;)

Barry Dahlberg

Ack, blog ate my HTML, or rather, didn't eat my HTML... should that be HtmlEncoded?

James L

WebForms, I do so hate thee...

Chris Cyvas

Your webform brings all the boys to the yard! ;)

I think the hipster coders might knock a few points off your "cool" factor for displaying such an antiquated technology. At least, that's what they would say. :)

zvolkov

Postbacks? Oh no! Even back in 2000 with classic ASP I always did command/query separation (or controller/view separation). View pages posted their forms to controller pages and controller pages redirected to view pages. You can do webforms but no posbacks for Christ sake!

Ryan Riley

If you are pulling YAGNI, why are you starting with ASP.NET? Why not start with your HTML? After all, ASP.NET is producing HTML forms, which are really just documents with a designated action attribute for processing (which is also optional). So you could in fact just have the form and then create an ASP or ASP.NET page for the processing, then redirect. Or use CGI and really go caveman style. :)

Seriously, though, how did you decide that classic WebForms was YAGNI? On what were you calling YAGNI? MVC? If so, I don't follow the logic as those are two different approaches to achieving the same thing. If you had called YAGNI on ASP.NET in favor of ASP, I would understand (and possibly agree).

Paul

What is this strange MasterPageFile you speak of? All looks a bit new and technical to me :)

Fair play man. If it doesn't change too much and isn't causing sleepless nights, roll with it.

Bradley Landis

zvolkov,

Wouldn't having controller pages and view pages right from the get go defeat the point of the experient. You Aren't Going To Need It! I think ayende is saying, he will gladly refactor to something like that when the need arises, he is just waiting for the need to arise.

Andrew

I know we all hate Web Forms, but really, we don't even know what this project/application is meant to do. If it's 3 web pages that show a grid with a few text boxes, Web Forms will be just fine..

Phil

I am calling YAGNI on this code. Why do users even need to login?

Frank Quednau

Nobody doubts this works, but it's brutal.

gunteman

I like it!

Tobin Harris

I like it too, beginners mindset in action. Also better than the 350+ LOC that comes with MVC AccountController (assuming userService isn't a refactoring of that).

Jason Stangroome

I'm really interested to see where this takes you as your application evolves. I presume you're still writing tests.

Chris Smith

If it works, does it matter? I've released a few things built this way and I've never had any trouble. I mean BIG things which have over a million hits a day.

Don't forget:

ViewState == ViewData

Code behind == Controller

Ayende Rahien

Chris,

Your parallels are quite mistaken

Chris Smith

I don't think there is a stable definition of MVC in a web context which we can build on. It means different things to different people. Ok slight clarification on my point..

View State <= ViewData. ViewData is actually greater than View State. You have to pass the state via View Data to the view. ASP.Net provides a black box abstraction for this and persists it automatically between requests. The concepts are equivalent and you do spend a lot of time building ASP.Net on top of ASP.Net MVC.

Code behind == Controller. Each is responsibly for managing UI state and interaction with the model. ASP.Net MVC uses request data for state management (you manually recover state). ASP.Net web forms manages state for you.

Same generalised concepts, different application.

MVC is so blurred, it's impossible to take sides.

Comment preview

Comments have been closed on this topic.

FUTURE POSTS

No future posts left, oh my!

RECENT SERIES

  1. RavenDB Sharding (2):
    21 May 2015 - Adding a new shard to an existing cluster, the easy way
  2. The RavenDB Comic Strip (2):
    20 May 2015 - Part II – a team in trouble!
  3. Challenge (45):
    28 Apr 2015 - What is the meaning of this change?
  4. Interview question (2):
    30 Mar 2015 - fix the index
  5. Excerpts from the RavenDB Performance team report (20):
    20 Feb 2015 - Optimizing Compare – The circle of life (a post-mortem)
View all series

RECENT COMMENTS

Syndication

Main feed Feed Stats
Comments feed   Comments Feed Stats