[ISSUE] SwiftUI preview builds fail due to missing Foundation import
Closed this issue · 2 comments
fabianmuecke commented
Describe the bug
In a Swift package, which depends on vgs-collect-ios, I cannot use SwiftUI previews. The preview build fails, because CharacterSet.decimalDigits
cannot be found. CharacterSet
is part of Foundation
, which is not imported in the file VGSDateFormat.swift
.
To Reproduce
Steps to reproduce the behavior:
- Create Swift package with a SwiftUI view
- Add dependency to vgs-collect-ios
- Try to use SwiftUI preview
- See error
Expected behavior
The preview build should not fail.
Environment (please complete the following information):
- SDK Version: latest master
- iOS Version: [e.g. iOS 13.1+]
- Xcode Version: 14.3.1
- Device: e.g. iPhone 14 Pro Simulator target
- Dependency manager and it's version:
- SPM
Possible Solution
Add import Foundation
to VGSDateFormat.swift
. Pull request incoming… 🙃
dmytrokhl commented
@fabianmuecke thanks, we will take a look.
dmytrokhl commented
@fabianmuecke this is fixed in v1.15.0.