WebSharper.UI 4.2.3
This is a feature release for WebSharper.UI 4.2. See the associated WebSharper release.
Enhancements
Templating type provider
- #161 Add
.Bind() : unit
template terminating method to directly bind holes to the current document. This is available on the client-side only if the template is declared withClientLoad.FromDocument
. - #161 Add optional argument
.Doc(keepUnfilled: bool)
for the server side to leave unfilled holes in the document, so that they can be used on the client side by.Bind()
.
WebSharper.CSharp
- #160 Add extension methods to bring C# in line with F#:
// Extensions on ListModel<K, T>: View<IEnumerable<V>> Map(Func<T, V> f); View<IEnumerable<V>> Map(Func<K, View<T>, V> f); View<IEnumerable<V>> MapLens(Func<K, Var<T>, V> f); Doc Doc(Func<T, Doc> f); Doc Doc(Func<K, View<T>, Doc> f); Doc DocLens(Func<K, Var<T>, Doc> f); ListModel<K, V> Wrap(Func<V, T> extract, Func<T, V> wrap, Func<V, T, V> update); // Extension on Var<FSharpList<T>>: Doc DocLens(Func<T, K> key, Func<K, Var<T>, Doc> f);