NetNewsWire/Frameworks/Account/FeedProvider/Twitter/TwitterExtendedEntities.swift

29 lines
493 B
Swift
Raw Normal View History

2020-04-18 20:46:28 +02:00
//
// TwitterExtendedEntities.swift
// Account
//
// Created by Maurice Parker on 4/18/20.
// Copyright © 2020 Ranchero Software, LLC. All rights reserved.
//
import Foundation
struct TwitterExtendedEntities: Codable {
let medias: [TwitterMedia]?
enum CodingKeys: String, CodingKey {
case medias = "media"
}
func renderAsHTML() -> String {
var html = String()
if let medias = medias {
for media in medias {
html += media.renderAsHTML()
}
}
return html
}
}