title: Load vendor scripts separately
body: <p>I have a Vue application A that as of now is simply a single file bundle that is built with webpack. This applications is using it's own API, and the bundle itself is accessed through that API as a static file.</p>
  
  <p>The bundle is used and run in a completely different application B (old ASP.NET WebForms). In that application I know the URL from which the bundle should be requested (cross-domain).</p>
  
  <p>This bundle is large (> 2mb, most code is third-party) and is cached, which means that once I update application A the changes are not immediately loaded in browser. I want to implement cache busting in some way.</p>
  
  <p>What is the best way to do it, considering my situation and limitations?</p>
  
  <p>Couple of own ideas:</p>
  
  <ol>
  <li><p>Configure (in some way) webpack so that browser only requests main bundle (with custom code) and then that bundle loads vendor scripts from separate file. The main bundle would not be cached (and will probably be small), while the vendor bundle would have some hash value in file name and would be cached by browser.</p></li>
  <li><p>Implement /version endpoint on the API of app A, call that endpoint before loading WebForms page of B and request the bundle file with latest version.</p></li>
  </ol>