kilko.de/tags/swift
- Decoding Unknown Data with Codable
A friend recently asked me how to decode the following JSON through Swift's Codable type. { "a": 1, "b": "foobar", "option.extra": { "a": 1 }, "option.extra.more": 4 } The problem is that only the first two keys (a and b) are … read more →
- Docker Swift Runtime
I recently wrote a small Vapor web app in Swift which I then wanted to deploy on my server inside a docker container. Not having all too much experience with docker my simple Dockerfile looked something like this. FROM swift:4 COPY . . EXPOSE 8080 RUN swift build --configuration release ENTRYPOI… read more →