@@ -1009,8 +1009,10 @@ private void appendNpmBundle(Element head, VaadinService service,
10091009 .compile ("src=\\ \" VAADIN\\ /build\\ /(.*\\ .js)\\ \" " )
10101010 .matcher (index );
10111011 while (scriptMatcher .find ()) {
1012- Element script = createJavaScriptModuleElement (
1013- "VAADIN/build/" + scriptMatcher .group (1 ), false );
1012+ Element script = createJavaScriptModuleElement (context
1013+ .getUriResolver ().resolveVaadinUri ("context://"
1014+ + "VAADIN/build/" + scriptMatcher .group (1 )),
1015+ false );
10141016 head .appendChild (script .attr ("async" , true )
10151017 // Fixes basic auth in Safari #6560
10161018 .attr ("crossorigin" , true ));
@@ -1021,8 +1023,9 @@ private void appendNpmBundle(Element head, VaadinService service,
10211023 .compile ("href=\\ \" VAADIN\\ /build\\ /(.*\\ .css)\\ \" " )
10221024 .matcher (index );
10231025 while (cssMatcher .find ()) {
1024- Element link = createStylesheetElement (
1025- "VAADIN/build/" + cssMatcher .group (1 ));
1026+ Element link = createStylesheetElement (context
1027+ .getUriResolver ().resolveVaadinUri ("context://"
1028+ + "VAADIN/build/" + cssMatcher .group (1 )));
10261029 head .appendChild (link );
10271030 }
10281031 return ;
@@ -1670,7 +1673,8 @@ protected static String getPushScript(BootstrapContext context) {
16701673 // Parameter appended to JS to bypass caches after version upgrade.
16711674 String versionQueryParam = "?v=" + Version .getFullVersion ();
16721675 // Load client-side dependencies for push support
1673- String pushJSPath = BootstrapHandlerHelper .getServiceUrl (request ) + "/" ;
1676+ String pushJSPath = context .getService ()
1677+ .getContextRootRelativePath (request );
16741678
16751679 if (request .getService ().getDeploymentConfiguration ()
16761680 .isProductionMode ()) {
0 commit comments