1
0
mirror of https://github.com/svg/svgo.git synced 2026-01-27 07:02:06 +03:00
Files
svgo/docs/04-plugins/removeDimensions.mdx
2024-06-16 00:10:42 +01:00

14 lines
624 B
Plaintext

---
title: removeDimensions
svgo:
pluginId: removeDimensions
---
Removes the [`width`](https://developer.mozilla.org/docs/Web/SVG/Attribute/width) and [`height`](https://developer.mozilla.org/docs/Web/SVG/Attribute/height) attribute from the top-most [`<svg>`](https://developer.mozilla.org/docs/Web/SVG/Element/svg) element if specified, and replaces it with the [`viewBox`](https://developer.mozilla.org/docs/Web/SVG/Attribute/viewBox) attribute if it's missing.
:::info
This is effectively the opposite of the [removeViewBox](/docs/plugins/removeViewBox/) plugin, ensure that is disabled before using this one.
:::