| Not OP, but where I work, we have a hybrid approach for our system. > Share code between your SPAs, for example, utilities? We alias a common folder for our utils with webpack which allows all our code to use the same utilities. We actually have two. One for shared frontend and backend, and one for just shared frontend > What if your SPAs have large dependencies (React, Vue), should every SPA come with their own? Webpack code splitting is how we split our apps. We also build into multiple bundles to keep bundle size small. That does mean that React does get bundled with each, but if you split thing appropriately, you can potentially save off a few MB with caching each bundle from page to page. > Should every SPA have its own build tools? With webpack, you can build all your bundles with one config / command > What if there's an update to a library, should it be allowed that one SPA runs on an older library? We have a root package.json for all of our react apps. This means that we don't update a library unless we can update it across the board. It takes more time to test upgrades, but it also means smaller bundles, easier package management and easier maintenance in the long run. |