mobileBoolean|String
(default: false)
If set to true
and the grid is viewed on mobile browser it will use adaptive rendering.
Can be set to a string phone
which will force the widget to use adaptive rendering regardless of browser type.
Avoid using the
mobile
option as it will be deprecated. Use theadaptiveMode
configuration option instead.
Important: With the mobile rendering, we recommend to set up the
height
option as well. Without setting an explicit height, every view of the grid might have a different height.
Example - enable adaptive rendering auto detect
<div id="grid"></div>
<script>
$("#grid").kendoGrid({
columns: [
{ field: "name" },
{ field: "age" },
{ command: "destroy" }
],
dataSource: [
{ name: "Jane Doe", age: 30 },
{ name: "John Doe", age: 33 }
],
filterable: true,
columnMenu: true,
mobile: true,
height: 550
});
</script>
Example - force adaptive rendering
<div id="grid"></div>
<script>
$("#grid").kendoGrid({
columns: [
{ field: "name" },
{ field: "age" },
{ command: "destroy" }
],
dataSource: [
{ name: "Jane Doe", age: 30 },
{ name: "John Doe", age: 33 }
],
filterable: true,
columnMenu: true,
mobile: "phone",
height: 550
});
</script>
In this article