Defaults icon indicating copy to clipboard operation
Defaults copied to clipboard

Version 10

Open sindresorhus opened this issue 3 years ago • 4 comments

Some ideas for version 10. It will not happen for a long time.

  • [ ] Deprecate .observe() and .publisher(): https://github.com/sindresorhus/Defaults/issues/71

sindresorhus avatar Nov 19 '22 16:11 sindresorhus

Uh... I just tried the latest DefaultsMacro and found that it brings too much performance burden (during the decoding process) comparing to use Combine-based Defaults.publisher() if the value type stored in the key is a complicated codable class / struct. I wonder what your suggestion is for replacing Defaults.publisher().

ShikiSuen avatar Jan 14 '25 13:01 ShikiSuen

Defaults.updates() is the replacement of Defaults.publisher().

sindresorhus avatar Jan 14 '25 13:01 sindresorhus

@sindresorhus Thanks for your suggestion. I wonder the following example of API migration is correct. Could you please help me take a look?

image

ShikiSuen avatar Jan 15 '25 12:01 ShikiSuen

Each Defaults.updates() needs a separate Task.

sindresorhus avatar Jan 15 '25 21:01 sindresorhus