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

Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported. #130

Open
RonLibero opened this issue Aug 29, 2022 · 0 comments

Comments

@RonLibero
Copy link

RonLibero commented Aug 29, 2022

When we use the 'leaflet-groupedlayercontrol' plugin, together with this EasyPrint plugin, we get an error by exporting the image.

 L.easyPrint({
            sizeModes: ['Current', 'A4Landscape', 'A4Portrait'],
            exportOnly: true,
            hideControlContainer: true,
        }).addTo(map);

On click export image, we receive the next console error:

oops, something went wrong! DOMException: Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported.
    at i3 (https://cityview.test:5173/node_modules/.vite/deps/leaflet-easyprint.js?v=55796427:66:71)

is there anyone who has a solution for this?

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

1 participant