Web projects always need CSS and script files.Bundling helps us to combine to multiple javascript and CSS file in to a single entity thus minimizing multiple requests in to a single
request.
For example consider the below web request to a page . This page consumes two JavaScript files “Javascript1.js” and “Javascript2.js”. So when this is page is requested it makes three request calls:-
One for the “Index” page.
Two requests for the other two JavaScript files “Javascript1.js” and “Javascript2.js”.
Below scenario can become worst if we have lot of javascript files resulting in many multiple requests thus decreasing performance. If we can somehow combine all the JS files in to a single bundle and request them as a single unit that would result in increased performance (See the next figure which has a single request).