Swiftpack.co - Package - artrmz/ReadTimePublishPlugin

ReadTime plugin for Publish

A Publish plugin that makes it easy to get a read time for your articles.

Installation

To install it into your Publish package, add it as a dependency within your Package.swift manifest:

let package = Package(
    ...
    dependencies: [
        ...
        .package(url: "https://github.com/artrmz/ReadTimePublishPlugin", from: "0.1.0")
    ],
    targets: [
        .target(
            ...
            dependencies: [
                ...
                "ReadTimePublishPlugin"
            ]
        )
    ]
    ...
)

For more information on how to use the Swift Package Manager, check its official documentation.

Usage

import ReadTimePublishPlugin
...
.unwrap(item.readTime().time, { .span("\($0) min") })
...

Github

link
Stars: 1

Dependencies

Used By

Total: 0

Releases

Version 0.1.0 - 2020-01-11 23:10:41

Initial release of the Read Time Publish plugin.