Virtual Classes
Read Anytime,Anywhere
Home
Knowledge
English
Grammar
Essay
हिंदी
व्याकरण
निबंध
Physics
Computers
MVC
Oops
JQuery
C++
ASP.NET
Interview FAQ
Download
Contact Us
Model
View
Controller
Layout Page
Partial View
Razor View Engine
Model Binding
Bundling In MVC
Routing in MVC
Request Life Cycle
ViewData\ViewBag
Filters
Bundling In MVC
A bundle is a logical group of files that is loaded with a single HTTP request.
By loading all the required Script and Stype file performace of processing request can be improved. You can create style bundle for css and script bundle for javascripts files in RegisterBundles method of BundleConfig class.
All bundles are registered in Application_Start method of Global.asax.
Below example shows registering of Bundles.
If you want to see the differnce in performance.
Open developer tool and click network tab and then refresh your page.
If you are not using bundling feature then browser makes request for every file needed to render page, but if you are using bundling feature then it make a single.