ASP.NET MVC:使用Kigg作为基础MVC应用程序

时间:2021-01-26 04:12:23

Looking to create my first MVC application. Coming from WebForms I'm pretty excited to create an application that I can easily test.

期待创建我的第一个MVC应用程序。来自WebForms我很高兴能够创建一个我可以轻松测试的应用程序。

I have looked into Kigg (the Digg clone done in MVC) and from the looks of it, it uses many of the best-practices in its architecture.

我已经研究过Kigg(在MVC中完成的Digg克隆),从它的外观来看,它使用了其架构中的许多最佳实践。

Having said that, would their approach be a good basis to base my web application (social networking site) on?

话虽如此,他们的方法是否是基于我的Web应用程序(社交网站)的良好基础?

I would say I understand about 80% of the code and can probably remove all of the stuff I would not need (in terms of the business objects he uses along with business rules).

我会说我理解了大约80%的代码,并且可能删除了我不需要的所有东西(就业务规则而言,他使用的业务对象)。

Would the benefit of having an architecture that uses best-practices in outweigh the cost of added complexity that perhaps "You Ain't Gonna Need It"?

拥有使用最佳实践的架构的好处是否会超过增加复杂性的成本,也许“你不需要它”?

2 个解决方案

#1


My suggestion for you is to start from scratch. Copy all the good things (pieces of code, patterns, good practices, etc) you see in KIGG if you like, but try to write/rewrite them yourself (if some class or piece of code is useful as it is, just copy/paste, there's no need to reach the extremes :P). That way you'll get the following benefits:

我的建议是从头开始。如果你愿意的话,复制你在KIGG中看到的所有好东西(代码片段,模式,良好实践等),但是尝试自己编写/重写它们(如果某些类或一段代码是有用的,只需复制/粘贴,没有必要达到极端:P)。这样你就会获得以下好处:

  • A solution that fits your exact needs (nothing more, nothing less).
  • 满足您的确切需求的解决方案(仅此而已,仅此而已)。

  • You will learn a lot faster (and a lot more!) by writing your own code rather than just reusing others code.
  • 通过编写自己的代码而不是仅仅重用其他代码,您将学得更快(以及更多!)。

  • You will feel comfortable with your own code standards which will make even easier to read the code.
  • 您将对自己的代码标准感到满意,这将使代码更容易阅读。

  • You can personalize the stuff you like.
  • 你可以个性化你喜欢的东西。

  • You probably will get a lot of errors or bugs if this is your first ASP.NET MVC app, but that is good, you'll learn a lot from these first mistakes.
  • 如果这是你的第一个ASP.NET MVC应用程序,你可能会遇到很多错误或错误,但这很好,你会从这些错误中学到很多东西。

That's the way I see it...

这就是我看到它的方式......

#2


I am the lead of KiGG, yes you are right that it has too many extension points, however I don't believe that 80% of code is just for extensibility. The goal of KiGG was to demonstrate that you can apply all of the best practices and yet be able to run an excellent application (DotNetShoutout.com). If need any clarification or if you think that we did some redundant things do let me know, I would be happy to help you.

我是KiGG的领导者,是的,你说它有太多的扩展点是正确的,但我不相信80%的代码只是为了扩展性。 KiGG的目标是证明您可以应用所有最佳实践,但能够运行出色的应用程序(DotNetShoutout.com)。如果需要任何澄清,或者如果您认为我们做了一些多余的事情,请告诉我,我很乐意为您提供帮助。

#1


My suggestion for you is to start from scratch. Copy all the good things (pieces of code, patterns, good practices, etc) you see in KIGG if you like, but try to write/rewrite them yourself (if some class or piece of code is useful as it is, just copy/paste, there's no need to reach the extremes :P). That way you'll get the following benefits:

我的建议是从头开始。如果你愿意的话,复制你在KIGG中看到的所有好东西(代码片段,模式,良好实践等),但是尝试自己编写/重写它们(如果某些类或一段代码是有用的,只需复制/粘贴,没有必要达到极端:P)。这样你就会获得以下好处:

  • A solution that fits your exact needs (nothing more, nothing less).
  • 满足您的确切需求的解决方案(仅此而已,仅此而已)。

  • You will learn a lot faster (and a lot more!) by writing your own code rather than just reusing others code.
  • 通过编写自己的代码而不是仅仅重用其他代码,您将学得更快(以及更多!)。

  • You will feel comfortable with your own code standards which will make even easier to read the code.
  • 您将对自己的代码标准感到满意,这将使代码更容易阅读。

  • You can personalize the stuff you like.
  • 你可以个性化你喜欢的东西。

  • You probably will get a lot of errors or bugs if this is your first ASP.NET MVC app, but that is good, you'll learn a lot from these first mistakes.
  • 如果这是你的第一个ASP.NET MVC应用程序,你可能会遇到很多错误或错误,但这很好,你会从这些错误中学到很多东西。

That's the way I see it...

这就是我看到它的方式......

#2


I am the lead of KiGG, yes you are right that it has too many extension points, however I don't believe that 80% of code is just for extensibility. The goal of KiGG was to demonstrate that you can apply all of the best practices and yet be able to run an excellent application (DotNetShoutout.com). If need any clarification or if you think that we did some redundant things do let me know, I would be happy to help you.

我是KiGG的领导者,是的,你说它有太多的扩展点是正确的,但我不相信80%的代码只是为了扩展性。 KiGG的目标是证明您可以应用所有最佳实践,但能够运行出色的应用程序(DotNetShoutout.com)。如果需要任何澄清,或者如果您认为我们做了一些多余的事情,请告诉我,我很乐意为您提供帮助。