Closed thatvirtualboy closed 1 year ago
Using your example in a SwiftUI button gives the error: Cannot find 'blocks' in scope in the Message() What am I missing?
Cannot find 'blocks' in scope
Message()
Button example:
Button(action: { // Create a block: let section = SectionBlock(text: Text("A message *with some bold text* and _some italicized text_.")) // Create the message: let message = Message(blocks: blocks, to: "#general", alternateText: "A message.") // Send the message: let webAPI = WebAPI(token: "xoxb-123456789") webAPI.send(message: message) }) { Label("Submit", systemImage: "paperplane") }
EDIT: Just saw your Tests folder. Which example should I follow for sending the most basic message?
Resolved
Using your example in a SwiftUI button gives the error:
Cannot find 'blocks' in scope
in theMessage()
What am I missing?Button example:
EDIT: Just saw your Tests folder. Which example should I follow for sending the most basic message?