commit 1f046ac021ed5ea18d7d13a95cca7576c8c0bb3e
parent bf4743253f4598fd09bc3b23504bc3a7e44e6d62
Author: William Casarin <jb55@jb55.com>
Date: Mon, 11 Apr 2022 10:55:03 -0700
use CachedAsyncImage for pfps
Signed-off-by: William Casarin <jb55@jb55.com>
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/damus/Views/EventView.swift b/damus/Views/EventView.swift
@@ -7,6 +7,7 @@
import Foundation
import SwiftUI
+import CachedAsyncImage
struct EventView: View {
let event: NostrEvent
@@ -15,7 +16,7 @@ struct EventView: View {
var body: some View {
HStack {
if let pic = profile?.picture.flatMap { URL(string: $0) } {
- AsyncImage(url: pic) { img in
+ CachedAsyncImage(url: pic) { img in
img.resizable()
} placeholder: {
Color.purple.opacity(0.1)