Shinkansen for ASP.NET MVC Now Available

Posted on March 28, 2010  |  

Posted in Development


While building Morts and Elvises with MVC2, I cut over Shinkansen to support MVC syntax within views and master pages.

I’ve included a sample MVC project, which you can either download from Codeplex or view online: view or download source code. In either case, peek inside Site.Master and you’ll see CSS includes at the top…

<%= ShinkansenMvc.Includes (c => 
    c.AddCss ("~/assets/css/addthis_widget.css");
    c.AddCss ("/assets/css/reset.css");
    c.AddCss ("assets/css/sifr.css");
    c.AddCss ("assets/css/sIFR-print.css");

… and JavaScript at the bottom.

<%= ShinkansenMvc.Includes (c => 
    c.AddJs ("~/assets/js/jquery-1.3.2.min.js");
    c.AddJs ("assets/js/sifr.js");
    c.AddJs ("/assets/js/styleswitcher.js");
    c.AddJs ("assets/js/swfaddress.js");

You can mix and match the two as you wish.

As always, feedback is welcome.


on April 2, 2010

Very handy code, thanks.

Great article :)

on April 8, 2010

Why you reinvent the wheel?

There are similar projects allready:

Will be better if you put your great skills into some existing project.