Skip to content

Instantly share code, notes, and snippets.

@fortmarek
Created September 9, 2020 14:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fortmarek/4410ac86ef94974803cf4959789c260d to your computer and use it in GitHub Desktop.
Save fortmarek/4410ac86ef94974803cf4959789c260d to your computer and use it in GitHub Desktop.
enum CodingKeys: String, CodingKey {
case template
}
init(from decoder: Decoder) throws {
let container = try decoder.container(keyedBy: CodingKeys.self)
template = try container.decode(Argument<String>.self, forKey: .template).wrappedValue
}
// Necessary for conforming ParsableArguments
init() {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment