Михаил Капелько vor 10 Monaten
Ursprung
Commit
86c5d1e7a9
2 geänderte Dateien mit 2 neuen und 2 gelöschten Zeilen
  1. +1
    -1
      src/Cord.Receive.swift
  2. +1
    -1
      src/V.swift

src/Cord.ReadOnly.swift → src/Cord.Receive.swift Datei anzeigen

@@ -1,7 +1,7 @@
import Combine

extension Cord {
final class ReadOnly<T>: ObservableObject {
final class Receive<T>: ObservableObject {
@Published var value: T
var subscriptions = [AnyCancellable]()

+ 1
- 1
src/V.swift Datei anzeigen

@@ -1,7 +1,7 @@
import SwiftUI

struct V: View {
@StateObject var isJoinAvailable = Cord.ReadOnly("joinAvailable", false)
@StateObject var isJoinAvailable = Cord.Receive("joinAvailable", false)
@StateObject var join = Cord.Button("join")
@StateObject var textF = Cord.TextField("text.app", "text.ui")
let test = Bus.Processor("text.ui", "joinAvailable", MeetupId.onlyAllowJoin)


Laden…
Abbrechen
Speichern