EditorDeserializationSettingsBuilder

Methods

Custom(System.Func)

Callback that allows custom deserialization to be plugged in. The method accepts string as the only parameter and is expected to return the modified content as string as well.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @( Html.Kendo().Editor()
                .Name("Editor")
                .Deserialization(d => d.Custom(@<text>
                    function(html) {
                        return html.replace(/(#)/, ",");
                    }
                    </text>)
                )
             )
             

Custom(System.String)

Callback that allows custom deserialization to be plugged in. The method accepts string as the only parameter and is expected to return the modified content as string as well.

Parameters

handler - System.String

The name of the JavaScript function that will be evaluated.

Example

Razor
 
             @( Html.Kendo().Editor()
                .Name("Editor")
                .Deserialization(d => d.Custom("htmlDeserialization"))
             )
             <script>
                function htmlDeserialization(html) {
                    return html.replace(/(<\/?)b(\s?)/, "$1strong$2");
                }
             </script>
             
In this article
MethodsCustom(System.Func)Custom(System.String)
Not finding the help you need?
Contact Support