Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AMD environment compatibility. #53

Open
juacas opened this issue Jun 30, 2017 · 3 comments · May be fixed by #159
Open

AMD environment compatibility. #53

juacas opened this issue Jun 30, 2017 · 3 comments · May be fixed by #159

Comments

@juacas
Copy link

juacas commented Jun 30, 2017

When using the library inside a AMD (requireJS) app I get an error probably related with the loading of lodash module. There are plans to package the library as AMD or UMD? There is a workaround for this issue?

Uncaught TypeError: _.forEach is not a function
at Object.init (instascan.js:7995)
at Stamp (instascan.js:26856)
at Function.create (instascan.js:27056)
at Scanner._createStateMachine (instascan.js:30311)
at new Scanner (instascan.js:30150)
at scanQR (play.js:866)
at HTMLFieldSetElement. (play.js:528)
at HTMLFieldSetElement.dispatch (jquery-2.1.4.min.js:3)
at HTMLFieldSetElement.r.handle (jquery-2.1.4.min.js:3)

@marverix
Copy link

Up

@mancioshell
Copy link

@schmich could you review my pull request to solve this issue?

@joshi1983
Copy link

joshi1983 commented Jul 26, 2019

I ran into a similar problem too using Durandal which uses requirejs and including the instascan.min.js.

I wonder if this issue is a duplicate or closely related to issue #94.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants