Latest 1.0.0
Homepage https://github.com/ji3g4kami/PostTime
License MIT
Platforms ios 12.0, requires ARC
Frameworks Security
Authors

The PostTime object can tell you how long ago from your given timestamp.

Tutuorial of how I created PostTime with TDD

Installation

To integrate PostTime into your Xcode project using CocoaPods, specify it in your Podfile:

source 'https://github.com/CocoaPods/Specs'

use_frameworks!

target '<Your Target Name>' do
    pod 'PostTime'
end

Then, run the following command:

$ pod install

Usage

You’ll need to import PostTime in swift files.

deviceID

This deviceID comes from keychain.

let postTime = PostTime(postDate: Date().timeIntervalSince1970 - 5.0)
print(postTime.howLongAgo())
// => 5 sec.

License

Copyright 2018 David Wu

Latest podspec

{
    "name": "PostTime",
    "platforms": {
        "ios": "12.0"
    },
    "module_name": "PostTime",
    "summary": "Measures the difference between two date",
    "requires_arc": true,
    "version": "1.0.0",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "David Wu": "[email protected]"
    },
    "homepage": "https://github.com/ji3g4kami/PostTime",
    "source": {
        "git": "https://github.com/ji3g4kami/PostTime.git",
        "tag": "1.0.0"
    },
    "frameworks": "Security",
    "source_files": "PostTime/*",
    "swift_version": "4.2",
    "static_framework": true
}

Pin It on Pinterest

Share This