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

fix(mergePaths): use a default floatPrecision #1945

Merged
merged 2 commits into from Feb 7, 2024
Merged

Conversation

KTibow
Copy link
Contributor

@KTibow KTibow commented Jan 27, 2024

Right now all plugins use a default floatPrecision except for mergePaths. This means that if another plugin doesn't round the paths internally, the whole precision leaks out.

We fix this by setting it to 3 by default. This closes #1944, and also probably helps with size reduction.

TODO: figure out a test case (feel free to suggest one)

Copy link
Member

@SethFalco SethFalco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TODO: figure out a test case (feel free to suggest one)

For something like this, I'm happy to shelve adding a test. The setting makes sense, so thank you for adding that.

@SethFalco SethFalco merged commit 9a7750f into svg:main Feb 7, 2024
8 checks passed
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 this pull request may close these issues.

Stringifies path data with extra 0s
2 participants