ListViewTagHelper

Example

Razor
<kendo-listview>
    <datasource></datasource>
    <flex />
    <grid />
    <listview-alt-template></listview-alt-template>
    <listview-edit-template></listview-edit-template>
    <listview-template></listview-template>
    <pageable></pageable>
    <scrollable />
    <selectable></selectable>
</kendo-listview>

ChildTags

Attributes

AttributeTypeDescription
nameStringSets the name of the component.
as-moduleBooleanSpecifies whether the initialization script of the component will be rendered as a JavaScript module.
bind-toIEnumerable<Object>Binds the ListView to a list of objects.
is-in-client-templateBooleanWhen placing a Tag Helper within a Kendo Template, set the type to text/html and add the is-in-client-template="true" attribute.
alt-templateStringTemplate to be used for rendering the alternate items in the listview.
alt-template-handlerStringTemplate to be used for rendering the alternate items in the listview. This option expects the name of a JavaScript function that will be called to return the template.
alt-template-idStringTemplate to be used for rendering the alternate items in the listview. This option expects the ID of the script element that contains the template.
alt-template-viewIHtmlContentTemplate to be used for rendering the alternate items in the listview. This option expects the instance containing the created HTML.
deferredBooleanSuppress initialization script rendering. Note that this options should be used in conjunction with DeferredScripts method.
aria-labelStringSets an aria-label attribute on the ListView content element (the element with role listbox or list).
auto-bindBooleanIf set to false the widget will not bind to the data source during initialization. In this case data binding will occur when the change event of the data source is fired. By default the widget will bind to the data source specified in the configuration.
borderedBooleanRenders border around the listview element.
bordersStringRenders border around the listview items. Valid values are: all: renders borders around listview items.; horizontal: renders top border of listview items. Useful when setting layout: "flex" and flex.direction: column. or vertical: renders top border of listview items. Useful when setting layout: "flex" and flex.direction: row..
content-elementStringDefines the type of element that holds the listview content.
datasource-idStringThe data source id
edit-templateStringSpecifies ListView item template in edit mode.
edit-template-handlerStringSpecifies ListView item template in edit mode. This option expects the name of a JavaScript function that will be called to return the template.
edit-template-idStringSpecifies ListView item template in edit mode. This option expects the ID of the script element that contains the template.
edit-template-viewIHtmlContentSpecifies ListView item template in edit mode. This option expects the instance containing the created HTML.
heightObjectThe height of the listview. Numeric values are treated as pixels.
layoutStringSpecify the layout of listview content. Valid options are: flex: This is equivalent to display: flex. It defines a flex container and enables a flex context for all its direct children. Think of flex items as primarily laying out either in horizontal rows or vertical columns. or grid: This is equivalent to display: grid. It defines the element as a grid container and establishes a new grid formatting context for its contents..
navigatableBooleanIndicates whether keyboard navigation is enabled/disabled.
on-cancelStringThe name of the JavaScript function that will handle the cancel event. Fired when the user clicks the "cancel" button.The event handler function context (available via the this keyword) will be set to the widget instance.
on-changeStringThe name of the JavaScript function that will handle the change event. Fires when the ListView selection has changed.The event handler function context (available via the this keyword) will be set to the widget instance.
on-data-bindingStringThe name of the JavaScript function that will handle the dataBinding event. Fires when the ListView is about to be bound.The event handler function context (available via the this keyword) will be set to the widget instance.
on-data-boundStringThe name of the JavaScript function that will handle the dataBound event. Fires when the ListView has received data from the DataSource and it is already rendered.The event handler function context (available via the this keyword) will be set to the widget instance.
on-editStringThe name of the JavaScript function that will handle the edit event. Fires when the ListView enters edit mode.The event handler function context (available via the this keyword) will be set to the widget instance.
on-removeStringThe name of the JavaScript function that will handle the remove event. Fires before the list view item is put in edit mode. If the event is not prevented, the ListView will call the DataSource sync method.The event handler function context (available via the this keyword) will be set to the widget instance.
on-saveStringThe name of the JavaScript function that will handle the save event. Fired when a data item is saved.The event handler function context (available via the this keyword) will be set to the widget instance.
script-attributesIDictionary<String,Object>Sets the attributes that will be added to the script tag of the component's initialization script.
tag-nameStringSpecifies ListView wrapper element tag name.
templateStringRepresents a collection of templates defined for the component.
template-handlerStringThe id of the template used for rendering the items in the listview. This option expects the name of a JavaScript function that will be called to return the template.
template-idStringThe id of the template used for rendering the items in the listview. This option expects the ID of the script element that contains the template.
template-viewIHtmlContentThe id of the template used for rendering the items in the listview. This option expects the instance containing the created HTML.
In this article
ExampleChildTagsAttributes
Not finding the help you need?
Contact Support