You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 19, 2020. It is now read-only.
There is currently a nightly feature for then and then_with functions on bools that allow them to be turned into Options using a provided value or closure.
This in conjunction with unwrap_or_default can be used to easily write "show this html or nothing" sections.
A stable shim trait for this could be added to this crate, have it live in experimental, and then remove it once the actual feature stabilizes.
There is currently a nightly feature for
then
andthen_with
functions onbool
s that allow them to be turned intoOptions
using a provided value or closure.This in conjunction with
unwrap_or_default
can be used to easily write "show this html or nothing" sections.A stable shim trait for this could be added to this crate, have it live in experimental, and then remove it once the actual feature stabilizes.
https://doc.rust-lang.org/std/primitive.bool.html#method.then_with
The text was updated successfully, but these errors were encountered: