Using Same Code in Different Mvc Solutions

asp.net-mvc, asp.net-mvc-areas, c#, partial-views, plugins

Solution

You could create a private Nuget and create a small installation for it. That way you can install, update, and uninstall directly from the package.

You can even make a localized package that you copy between computers. Nuget has a very easy way to specify where you want to extract files to, and what files you want to extract.

Problem

I'm using asp.net mvc 3 and .net framework 4.0 with C# Let's say I have NivoSlider( a slider ) html code. Also it has js, css and image files. I want to use the NivoSlider cshtml code and js/css/images as "a project" and I want to add it to different MVC solutions. It will become a plugin some-how. I can't make it a partialview, because I have to move all the css, js and imges files into new solution. I looked at "mvc areas" but it's not rendering my js and css files ( as a matter of fact; using "Areas" is not a perfect way as you know )... I looked up some plugin based architectures, but none-of-them are easy to implement. I have limited time. So how can I solve this problem ? EDIT: I can use this http://razorgenerator.codeplex.com/ - But I'm looking for another solutions if you came up with an idea...

Original source

Related problems