- Swift 4.1 support
- Added
Codable
support! - Added generic subscripts support (better
DefaultsKey
init diagnostics and accessingDefaults[.key]
) @sunshinejr - Added default values protocols (
DefaultsDefaultValueType
,DefaultsDefaultArrayValueType
) - this means that you can extend any type with default value so you can create non-optionalDefaultsKey
afterwards! @sunshinejr - Added default values in
DefaultsKey
, e.g.DefaultsKey<String>("test", defaultValue: "default value")
@sunshinejr - Added better support for custom types: using
DefaultsSerializable
, when your type implementsNSCoding
,RawRepresentable
(enums as well) orCodable
, you get default implementations for free! @sunshinejr - Added automatic array support for any type that is available to
SwiftyUserDefaults
(means custom withDefaultsSerializable
as well!) @sunshinejr - Added Swift Package Manager support! @sunshinejr
- Added
[URL]
built-in support! @sunshinejr - A lot of infrastructure changes (CI, project), around 350 tests to make sure all of the changes work properly! @sunshinejr
- Removed legacy strings based API (
Defaults["test"]
),Dictionary
andAny
support (sorry, with all the changes in the library we had to, but you probably can bring it back withDefaultsSerializable
anyways 😅) @sunshinejr
- Fix for Swift Package Manager #114 @max-potapov
This is the Swift 3 update version.
It contains no major changes in the library itself, however it does change some APIs because of Swift 3 requirements.
- Update documentation and README for Swift 3
- Updated for Swift 3 and Xcode 8 compatibility #91 @askari01
- Updated for Swift 3 beta 4 #102 @rinatkhanov
- Updated for Swift 3 beta 6 #106 @ldiqual
NSUserDefaults.set()
is now public (useful for adding support for custom types) #85 @goktugyil- Support for Xcode 8 (Swift 2.3) for Carthage users #100 @KevinVitale
- Support for
archive()
andunarchive()
onRawRepresentable
types - Improved documentation
- Fix Carthage build
- Suppress deprecation warnings in tests
- Fixed infinite loop bug
- Added Travis CI integration
- Added Swift Package Manager support
- Documentation improvements
- Added
removeAll()
- Added tvOS and watchOS support
- Fixed error when linking SwiftyUserDefaults with app extension targets
- Minor tweaks and fixes
- Introducing statically-typed keys
- Define keys using
DefaultsKey
- Extend magic
DefaultsKeys
class to get access toDefaults[.foo]
shortcut - Support for all basic types, both in optional and non-optional forms
- Support for arrays of basic types, such as
[Double]
or[String]?
- Support for basic
[String: AnyObject]
dictionaries hasKey()
andremove()
for static keys- You can define support for static keys of custom
NSCoder
-compliant types - Support for
NSURL
in statically-typed keys
- Define keys using
- [Carthage] Added OS X support
Deprecations
+=
,++
,?=
operators are now deprecated in favor of statically-typed keys
- Added non-optional
Proxy
getters- string -> stringValue, etc.
- non-optional support for all except NSObject and NSDate getters
- Fixed Carthage (Set iOS Deployment target to 8.0)
- Converted tests to XCTest
- Carthage support
- Swift 1.2 compatibility
- Fixed podspec
- Initial release
Proxy
getters:- String, Int, Double, Bool
- NSArray, NSDictionary
- NSDate, NSData
- NSNumber, NSObject
- subscript setter
hasKey()
remove()
?=
,+=
,++
operators onProxy
- global
Defaults
shortcut