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
I have a hybrid AngularJS/Angular app. To support the legacy code, window._ references Underscore.
However, when I make the call to loadConnectAndInitialize (which adds the connect-js library to the page because I'm importing it using @stripe/connect-js/pure), window._ is reassigned to reference Lodash (v4.17.21), which breaks our legacy code (Underscore has some methods that Lodash does not).
This is using connect-js v3.3.16.
Would it be possible to scope that reference within the connect-js library instead of rewriting _ on the window object?
The text was updated successfully, but these errors were encountered:
mikejacobson-MyTime
changed the title
Calling loadConnectAndInitialize reassigns window._ to lodash v4.17.21
Adding connect-js to page reassigns window._ to lodash v4.17.21
Oct 29, 2024
I have a hybrid AngularJS/Angular app. To support the legacy code,
window._
references Underscore.However, when I make the call to
loadConnectAndInitialize
(which adds the connect-js library to the page because I'm importing it using@stripe/connect-js/pure
),window._
is reassigned to reference Lodash (v4.17.21), which breaks our legacy code (Underscore has some methods that Lodash does not).This is using connect-js v3.3.16.
Would it be possible to scope that reference within the connect-js library instead of rewriting
_
on the window object?Here's a StackBlitz demonstrating the issue:
https://stackblitz.com/edit/stackblitz-starters-5mcvnf?file=src%2Fmain.ts
Instructions are on its page.
The text was updated successfully, but these errors were encountered: