Questions tagged [bundling]
9 questions
10
votes
1 answer
Is it better practice to bundle scripts into a single bundle per page, or have several bundles?
In a web application I'm working on, there are 3 types of scripts (same applies to stylesheets):
Those needed on every single page (e.g. jquery)
Those needed on several pages, but not all (e.g. a lightbox library used on pages which show user…

Tim
- 210
- 1
- 6
9
votes
3 answers
Is it a good practice to have one bundle per view in Asp Net MVC
Since bundling and minification is all about optimization and making pages load faster, it appears to me that it would be logical to create one bundle for scripts and one bundle for styles per view basis, so that to load all scripts and styles a…

Mykhailo Seniutovych
- 273
- 2
- 3
- 6
9
votes
1 answer
Should I download scripts from a CDN or bundle everything into one script?
I am using jQuery, angular, bootstrap, along with some custom js files. Currently, I have everything bundled into one script. Since, jQuery, angular, and bootstrap are available via CDN, is it better to just grab them from the CDN or should I keep…

xaisoft
- 445
- 5
- 12
8
votes
2 answers
Should I group all of my .js files into one large bundle?
One of the difficulties I'm running into with my current project is that the previous developer spaghetti'd the javascript code in lots of different files. We have modal dialogs that are reused in different places and I find that the same .js file…

Scottie
- 429
- 1
- 5
- 11
5
votes
3 answers
Using SPA ( Single-page-application) in production with separate configuration file/module
Problem statement
dev team
Dev team wants to pre-build the SPA's (Angular App & React App) and provide single package containing JS, CSS, & HTML file. There's no server-side rendering / lazy loading also. Hence, configurations like service URL, app…

Prajwal
- 161
- 1
- 5
4
votes
1 answer
Can I bundle my JavaScript code with an MIT licensed code and keep my code unaffected from the MIT license?
Can I bundle my proprietary JavaScript code with MIT licensed libraries (e.g. JQuery, AngularJS) into the same file, distribute it via HTTP but disallow my users to use my own code as an MIT licensed code?
This way I could minimize the number of…

Tamas
- 143
- 4
2
votes
1 answer
New components that implement an abstract component, vs variants on a single component.
I have created some stateless functional components that represent round social media icons used for links/sharing, the code looks like this:
AbstractRound
import React from 'react';
import { withStyles } from '@material-ui/core/styles';
const…

dwjohnston
- 2,543
- 6
- 29
- 49
1
vote
1 answer
How do webpack and gulp complement each other?
I've started with TypeScript 2.5 years ago with Visual Studio and ASP.Net MVC. VS Web Essentials would compile ts files on save and the WebOptimizer library would bundle them together at runtime in a specific order. Basically a disaster, once the…

peter
- 113
- 7
0
votes
1 answer
Bundling style and script files in asp MVC layout page
How to bundle style and script files using layout in asp MVC?
Here is an example.
Layout1 uses style and script file for header and footer functionality. Sections are declared.
View1 uses Layout1 . It also contains style and script files in order to…

John
- 773
- 2
- 7
- 19