You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// plugin for generating HTML files from rolluphtml({// [not working yet] don't build mobile (we have another rollup.config.mobile.js for that)exclude: ['mobile/**', ...pagesToIgnore],// keep our file structure intactflattenOutput: false,// the root directory to start atrootDir: 'source',// keep non-module assetsextractAssets: true,// make whitelabel replacements (if whitelabel exists)transformHtml: (html)=>{if(!!WHITELABEL_NAME)html=html.replace(/Katapult/g,WHITELABEL_NAME);returnhtml;}})
The problem here is that after being bundled, the page will now execute the ../katapult-maps-desktop.js script before the ../app-configuration.js script which is not the correct order according to the pre-bundled file. This issue came about when upgrading from rollup@2.79.1 to v3. Also interestingly, this only happens to certain pages. We have multiple pages in our app with similar index.html files as this one but it seems random as to which ones build with an incorrect script order and which ones build correctly. Any help would be appreciated!
The text was updated successfully, but these errors were encountered:
Update! While this still does seem like a bug, my workaround was to import app-configuration.js at the top of katapult-maps-desktop.js instead of it being imported using a script tag.
aigan
linked a pull request
Dec 5, 2023
that will
close
this issue
Versions
@web/rollup-plugin-html
: 2.0.1rollup
: 3.29.3Plugin config
Pre-bundled index.html file
Bundled index.html file
Issue
The problem here is that after being bundled, the page will now execute the
../katapult-maps-desktop.js
script before the../app-configuration.js
script which is not the correct order according to the pre-bundled file. This issue came about when upgrading fromrollup@2.79.1
to v3. Also interestingly, this only happens to certain pages. We have multiple pages in our app with similar index.html files as this one but it seems random as to which ones build with an incorrect script order and which ones build correctly. Any help would be appreciated!The text was updated successfully, but these errors were encountered: