thoughtTemplateFunction(default: null)

A function used to render each thought item. Receives each item from the thoughts array as the first argument and must return an HTML string.

Example - use a custom thought template

<div id="chain"></div>
<script>
$("#chain").kendoChainOfThought({
    label: "Reasoning",
    expandable: true,
    expanded: true,
    thoughts: [
        { label: "Step one" },
        { label: "Step two" }
    ],
    thoughtTemplate: function(thought) {
        return "<div class='k-thought'><span class='k-agent-step-content'><span class='k-agent-step-label'>" + kendo.htmlEncode(thought.label) + "</span></span></div>";
    }
});
</script>
In this article
thoughtTemplate
Not finding the help you need?
Contact Support