Swiftpack.co - swift-cloud/ComputeUI as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by swift-cloud.
swift-cloud/ComputeUI 1.0.1
Write SwiftUI / Tokamak apps on Fastly Compute@Edge
⭐️ 24
🕓 1 year ago
iOS macOS watchOS tvOS driverKit macCatalyst
.package(url: "https://github.com/swift-cloud/ComputeUI.git", from: "1.0.1")

ComputeUI

Build server side rendered webpages in SwiftUI

import ComputeUI

struct IndexPage: View {

    @Environment(\.request) var req

    var body: some View {
        VStack {
            Text("Hello, Swift")
                .font(.title)

            Text("This is a server rendered SwiftUI website")
                .font(.subheadline)

            Text("Your ip address \(req.clientIpAddress().stringValue)")
        }
    }
}

try await Router()
    .get("/", IndexPage())
    .listen()

GitHub

link
Stars: 24
Last commit: 1 year ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Release Notes

v1.0.1 - Initial Release
1 year ago

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics