In many cases, a component is only used within a <Svg> or <Canvas> context. While it's very convenient to have a single component that works across all contexts, it does increase bundle size to load the Svg or Canvas implementations for all components when you are only using one of them.
The proposal is to still provide a unified component, but also provide context-specific instances, such as:
Text
- simple facade that uses the the below
TextSvg
TextCanvas
TextHtml (future)
TextBase (possible to simplify the aforementioned)
This should significantly reduce bundle sizes. Will take some thought on how to do this surgically.
In many cases, a component is only used within a
<Svg>or<Canvas>context. While it's very convenient to have a single component that works across all contexts, it does increase bundle size to load the Svg or Canvas implementations for all components when you are only using one of them.The proposal is to still provide a unified component, but also provide context-specific instances, such as:
TextTextSvgTextCanvasTextHtml(future)TextBase(possible to simplify the aforementioned)This should significantly reduce bundle sizes. Will take some thought on how to do this surgically.