Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/johnsundell/splashpublishplugin
A Splash plugin for the Publish static site generator
https://github.com/johnsundell/splashpublishplugin
plugin publish publish-plugin splash syntax-highlighting
Last synced: about 2 months ago
JSON representation
A Splash plugin for the Publish static site generator
- Host: GitHub
- URL: https://github.com/johnsundell/splashpublishplugin
- Owner: JohnSundell
- License: mit
- Created: 2019-12-30T19:30:38.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-08-12T21:05:45.000Z (over 2 years ago)
- Last Synced: 2024-10-14T01:24:10.756Z (2 months ago)
- Topics: plugin, publish, publish-plugin, splash, syntax-highlighting
- Language: Swift
- Homepage:
- Size: 7.81 KB
- Stars: 91
- Watchers: 4
- Forks: 22
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Splash plugin for Publish
A [Publish](https://github.com/johnsundell/publish) plugin that makes it easy to integrate the [Splash](https://github.com/johnsundell/splash) Swift syntax highlighter into any Publish website.
## Installation
To install it into your [Publish](https://github.com/johnsundell/publish) package, add it as a dependency within your `Package.swift` manifest:
```swift
let package = Package(
...
dependencies: [
...
.package(name: "SplashPublishPlugin", url: "https://github.com/johnsundell/splashpublishplugin", from: "0.1.0")
],
targets: [
.target(
...
dependencies: [
...
"SplashPublishPlugin"
]
)
]
...
)
```Then import SplashPublishPlugin wherever you’d like to use it:
```swift
import SplashPublishPlugin
```For more information on how to use the Swift Package Manager, check out [this article](https://www.swiftbysundell.com/articles/managing-dependencies-using-the-swift-package-manager), or [its official documentation](https://github.com/apple/swift-package-manager/tree/master/Documentation).
## Usage
The plugin can then be used within any publishing pipeline like this:
```swift
import SplashPublishPlugin
...
try DeliciousRecipes().publish(using: [
.installPlugin(.splash(withClassPrefix: "classPrefix"))
...
])
```