Modernize NSDate and Date implementation introducing breaking changes#759
Modernize NSDate and Date implementation introducing breaking changes#759mokagio merged 4 commits intomokagio/rfc-3339from
NSDate and Date implementation introducing breaking changes#759Conversation
The breaking change is actually in having removed `NSDate.rfc3339Formatter`, which is no longer necessary.
| var wordPressComJSONString: String { | ||
| DateFormatter.wordPressCom.string(from: self) | ||
| } | ||
| } |
There was a problem hiding this comment.
I feel like these extension functions don't really help much. They can just use the formatter instance DateFormatter.wordPressCom directly, right?
There was a problem hiding this comment.
Sorry, I just noticed wordPressCom is an internal API. Please ignore my comment above, if you intend to not expose the DateFormatter as public API, which I think is a good idea (leaving us option to switch over to ISO8601DateFormatter).
There was a problem hiding this comment.
👍
Yes. This whole custom formatting feels odd. I think once we get the code in a better place in term of SPM, we could look at trimming some of those unnecessary custom bits in favor of standards
crazytonyli
left a comment
There was a problem hiding this comment.
I'm okay with merging these two PR together as one. It might be easier for code review 🙈
Follows up on @crazytonyli comments from the PR #758, which it targets.
I don't know why I felt like making a dedicated PR instead of pushing to that one directly 🤷♂️ Maybe because of the breaking changes...
CHANGELOG.mdif necessary. — N.A.