Closed sam-s4s closed 10 months ago
As an update, I found the commit that contains the break:
https://github.com/Cordobo/angularx-qrcode/commit/f16ea7d9af11d5f3c29145ae8516085f17832a75
"@types/qrcode": "1.5.0",
was moved from devDependencies
to dependencies
.
Quite recent, added in version 15.0.1, Dec 15, 2022. Now I understand that version 15.0.0 was broken because it lacked this declaration, but version 14 didn't require it. It used to pull QRCodeErrorCorrectionLevel
from types.ts
but now it gets it from qrcode
.
It would be great if this could be resolved :D Thank you!
Thanks to @jamesanderson9182 we have PR and a new release 👍
Ok I have updated to the new version, but I think we missed a spot :(
projects/angularx-qrcode/package.json
"dependencies": {
"@types/qrcode": "1.5.0",
"qrcode": "1.5.1"
},
@types/qrcode uses @types/node :(
I think we need to move that to devDependencies, too?
Ok I have added a PR for that change, I'm hoping that fixes it!
I think the general pattern is that types should normally be added only to devDependencies.
I am hoping that might stop it from propagating throughout the app that is using angularx-qrcode.
(sometimes @types/node feels like a virus lol)
@Cordobo if you're around, would you mind giving this a look :) https://github.com/Cordobo/angularx-qrcode/pull/222
Sorry for the delay, I was on vacation. I'm updating it this weekend right now.
Fixed with angularx-qrcode 16.0.2! Thanks for your contributions 👍
Hi there. First of all, I'd like to say thank you for all your hard work on this project <3
I've just upgraded from Angular 13 to 15, and thus now upgraded to angularx-qrcode 15.
Unfortunately there is a problem with this new version, in that this project uses
"@types/qrcode": "1.5.0"
as a dependency, which, in turn, uses@types/node
, pulling in all those types into our root project that uses angularx-qrcode - which needs to be avoided in a web environment (such as we run angularx-qrcode in).We get nasty side-effects from the node types being added into the project, such as the return of
setTimeout
andsetInterval
beingNodeJS.Timer
instead ofnumber
.Thanks!