This library is now deprecated in favour of a more complete and SwiftUI friendly TextEditor
backport:
https://github.com/shaps80/SwiftUIBackports
See it in action here: https://twitter.com/shaps/status/1654972428286668800?s=20
extension Result { | |
public func `catch`(_ handler: () throws -> Success) -> Result<Success, Error> { | |
flatMapError { _ in | |
.init { try handler() } | |
} | |
} | |
public func `catch`(_ handler: (Failure) throws -> Success) -> Result<Success, Error> { | |
flatMapError { error in | |
.init { try handler(error) } |
This library is now deprecated in favour of a more complete and SwiftUI friendly TextEditor
backport:
https://github.com/shaps80/SwiftUIBackports
See it in action here: https://twitter.com/shaps/status/1654972428286668800?s=20
// Simplest possible custom card | |
// Does nothing. Doesn't look like anything | |
class MyCustomCard extends HTMLElement { | |
setConfig(config) { | |
// The config object contains the configuration specified by the user in ui-lovelace.yaml | |
// for your card. | |
// It will minimally contain: | |
// config.type = "custom:my-custom-card" |
Panic's Developer ColorPicker (v1.5.4) does not work in macOS Catalina or macOS BigSur. This is due to enforcement of code-signing. Until Panic releases a newer version that supports Catalina/BigSur, below is the workaround.
You need a Developer Account. This could be a free account. Refer: https://9to5mac.com/2016/03/27/how-to-create-free-apple-developer-account-sideload-apps/