Skip to content

Commit 46d115e

Browse files
authored
Merge pull request #13 from robb/swim
Rename to Swim, move HTML into its own target.
2 parents 4b25b2e + 582f63e commit 46d115e

File tree

10 files changed

+31
-2
lines changed

10 files changed

+31
-2
lines changed

Generator/Sources/Generator/main.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ struct Generator: ParsableCommand {
77
.joined(separator: "\n\n\n")
88

99
print("// This output is machine generated and should not be edited manually.")
10+
print("\n")
11+
print("@_exported import Swim")
12+
print("\n")
1013
print(output)
1114
}
1215
}

Package.swift

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,22 @@ let package = Package(
1010
.library(
1111
name: "HTML",
1212
targets: ["HTML"]),
13+
.library(
14+
name: "Swim",
15+
targets: ["Swim"]),
1316
],
1417
targets: [
1518
.target(
1619
name: "HTML",
17-
dependencies: []),
20+
dependencies: ["Swim"]),
1821
.testTarget(
1922
name: "HTMLTests",
2023
dependencies: ["HTML"]),
24+
.target(
25+
name: "Swim",
26+
dependencies: []),
27+
.testTarget(
28+
name: "SwimTests",
29+
dependencies: ["HTML"]),
2130
]
2231
)

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1-
# HTML DSL
1+
# Swim – Swift Marktup
22

33
A DSL for building HTML documents with Swift [function builders].
44

55
Currently in use on [my personal website].
66

77
```swift
8+
import Swim
9+
import HTML
10+
811
let myDocument = html(lang: "en-US") {
912
head {
1013
meta(charset: "utf-8", content: "text/html", httpEquiv: "Content-Type")

Sources/HTML/Tags.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
// This output is machine generated and should not be edited manually.
2+
3+
4+
@_exported import Swim
5+
6+
27
/// a
38
///
49
/// Hyperlink.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

Tests/HTMLTests/HTMLTests.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
import XCTest
2+
import Swim
3+
24
@testable import HTML
35

46
final class HTMLTests: XCTestCase {

Tests/SwimTests/SwimTests.swift

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import XCTest
2+
3+
@testable import Swim
4+
5+
final class SwimTests: XCTestCase {
6+
7+
}

0 commit comments

Comments
 (0)