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

3.0.8 breaks require("canvg") #1484

Closed
shanebdavis opened this issue Sep 30, 2021 · 6 comments
Closed

3.0.8 breaks require("canvg") #1484

shanebdavis opened this issue Sep 30, 2021 · 6 comments

Comments

@shanebdavis
Copy link

shanebdavis commented Sep 30, 2021

3.0.7 works with require("canvg")

(NodeJS v14.17.0; NPM v7.6.0)

I understand there is a desire to move towards ES modules, but 3.0.8 was a patch update; it shouldn't cause breaking changes. If such a breaking change is needed to further ES-module support, that should be a major version change e.g. 4.0.0.

I'd like to request a 3.0.9 release that restores CommonJS compatibility and a 4.0.0 release with the new ES-module changes.

@dangreen
Copy link
Collaborator

dangreen commented Oct 5, 2021

@shanebdavis can you try canvg@3.0.9 ?

@Jason-Morcos
Copy link

3.0.9 still appears broken to me. 3.0.7 works perfectly (I use canvg as part of a process to download an SVG as an image) but 3.0.8 and 3.0.9 both only produce a blank white image. Honestly I'm not sure what issues it's related to and am happy to open a new issue certainly, but it appears to me likely related to 3.0.8 generally being a patch-release-regression and I'm not sure what, if anything, makes my setup unique. I use Canvg in the import Canvg from 'canvg'; style, but I use it in a web application so it makes me think that perhaps this is related to changing the type of the package as 3.0.8 did. I have no errors in my console nor when webpacking, it just downloads a blank image.

@dangreen
Copy link
Collaborator

@Jason-Morcos Hi. Can you provide example of SVG?

@Jason-Morcos
Copy link

Hi @dangreen, thank you for the reply!
The SVG is inline rendered within html so I did the best I could (copied into vs code and saved as SVG). I also included the png shown from downloading via the browser (browser-side JS calling canvg). The image download does work still with 3.0.7 so we've reverted production to that release, but I'm happy to keep trying each new version/any possible fix version to see if it's resolved and to try to garner any additional debug info as needed.

Extracted SVG:
map2.svg.zip

Download using 3.0.9:
mapDownloaded

Download using 3.0.7:
Downloaded307

@dangreen
Copy link
Collaborator

@Jason-Morcos I can't reproduce this issue: on demo page all works fine

Снимок экрана 2021-10-18 в 16 02 50

Can you please provide minimal repo with reproduction?

@dangreen
Copy link
Collaborator

dangreen commented Apr 7, 2022

Closed due to inactivity.

@dangreen dangreen closed this as completed Apr 7, 2022
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

No branches or pull requests

3 participants