A user reached out about the compendium library not working. After investigating the issue, it turns out to be caused by the "Better Roll Tables" module being loaded.
The reason for that is because that module apparently creates a exports global variable, which will cause every UMD dependency and build to fail, because it would cause the js umd packages to be installed under exports["pkg"] instead of window["pkg"] making those classes unavailable.
This is what happens when we open the compendium library, it loads the vue dependency component which then gets set in exports["ForgeCompendiumBrowserVue"] instead of being a global variable on window, causing this failure:

and this effect:

There's two actions to do here:
1 - report the issue to that module developer, because I'm sure it will be affecting potentially many other modules that may depend on build umd files or external dependencies
2 - perhaps modify dlopen so that it checks for a exports variable and renames it or keeps track of the variables in it so that when a dependency is loaded, it can copy the new fields into globalThis.window
Possibly do the same thing for the define method if it exists. See UMD format and how it loads dependencies:
https://jameshfisher.com/2020/10/04/what-are-umd-modules/
A user reached out about the compendium library not working. After investigating the issue, it turns out to be caused by the "Better Roll Tables" module being loaded.


The reason for that is because that module apparently creates a
exportsglobal variable, which will cause every UMD dependency and build to fail, because it would cause the js umd packages to be installed underexports["pkg"]instead ofwindow["pkg"]making those classes unavailable.This is what happens when we open the compendium library, it loads the vue dependency component which then gets set in
exports["ForgeCompendiumBrowserVue"]instead of being a global variable onwindow, causing this failure:and this effect:
There's two actions to do here:
1 - report the issue to that module developer, because I'm sure it will be affecting potentially many other modules that may depend on build umd files or external dependencies
2 - perhaps modify
dlopenso that it checks for aexportsvariable and renames it or keeps track of the variables in it so that when a dependency is loaded, it can copy the new fields intoglobalThis.windowPossibly do the same thing for the
definemethod if it exists. See UMD format and how it loads dependencies:https://jameshfisher.com/2020/10/04/what-are-umd-modules/