The gram library requires Swift 5.8 or later.
| Platform | Status |
|---|---|
| 💬 Documentation | |
| 🐧 Linux | |
| 🍏 Darwin | |
| 🍏 Darwin (iOS) | |
| 🍏 Darwin (tvOS) | |
| 🍏 Darwin (visionOS) | |
| 🍏 Darwin (watchOS) |
To use gram in a project, add the following to your Package.swift file:
let package: Package = .init(
...
dependencies: [
// other dependencies
.package(url: "https://github.com/rarestype/gram", from: "1.0.0"),
],
targets: [
.target(
name: "example",
dependencies: [
.product(name: "Grammar", package: "gram"),
// other dependencies
]
),
// other targets
]
)