plugin

Helper method for writing new widgets. Exposes a jQuery plug-in that will handle the widget creation and attach its client-side object in the appropriate data-* attribute.

Example

function TextBox(element, options) {
}

kendo.ui.plugin(TextBox);

// initialize a new TextBox for each input, with the given options object.
$("input").kendoTextBox({ });
// get the TextBox object and call the value API method
$("input").data("kendoTextBox").value();

Parameters

widget kendo.ui.Widget

The widget function.

register Object (default: kendo.ui)

The object where the reference to the widget is recorded.

prefix String (default: "")

The plugin function prefix, e.g. "Mobile" will register "kendoMobileFoo".

In this article