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
affjax v12 is broken when bundled with webpack. It uses module.require to detect the environment(node or web), but webpack does not defined module.require resulting in it generating node bundles using XMLHttpRequest instead of xhr2 node module, and requests failing with Error: (ClientHttpError There was a problem making the request: XMLHttpRequest is not defined). In short, it will always assume webpack is generating browser bundle.
Looks like v13 allows environment detection to be handled by user by giving affjax-web and affjax-node modules. It would be nice to update affjax version.
The text was updated successfully, but these errors were encountered:
Another problem I see here is that it does not allow to write platform-agnostic code. We can't really dispatch on dependencies based on runtime options, at least our existing setup does not have this option.
I see, I didn't know it had different PS version. In Liqwid, I was able to fix it by using revision of affjax(e717b1).
Alternatively, perhaps would it be nice to include docker image builder that does not bundle with webpack on CTL nix infrastructure? Currently, we use bundlePursProject, but I think it can be done without bundling.
affjax
v12 is broken when bundled with webpack. It usesmodule.require
to detect the environment(node or web), but webpack does not definedmodule.require
resulting in it generating node bundles usingXMLHttpRequest
instead ofxhr2
node module, and requests failing withError: (ClientHttpError There was a problem making the request: XMLHttpRequest is not defined)
. In short, it will always assume webpack is generating browser bundle.Looks like v13 allows environment detection to be handled by user by giving
affjax-web
andaffjax-node
modules. It would be nice to updateaffjax
version.The text was updated successfully, but these errors were encountered: