Swiftpack.co - Package - shaps80/ScaledMetric

ios tv watch mac

ScaledMetric

A dynamic property wrapper that scales a numeric value. Identical to the new iOS 14 implementation, but back-ported to suport iOS 13 as well.

Usage

@ScaledMetric(wrappedValue: 4)
private var spacing: CGFloat

...
// the spacing will automatically scale with the current `ContentSizeCategory` value
VStack(spacing: spacing) { ... }

Installation

Add https://github.com/shaps80/ScaledMetric.git to your Swift Packages.

Github

link
Stars: 0

Dependencies

Used By

Total: 0