Skip to content
Desislava Mihaylova edited this page Apr 28, 2016 · 3 revisions

The Configuration section shows the options of a widget or other component - the supported configuration settings. Here is an example:

### autoBind `Boolean` *(default: true)*

If set to `false` the widget will not bind to the data source during initialization. In this case data binding will occur when the [change](/api/framework/datasource#events-change) event of the
data source is fired.

By default this option is set to `true` which means that the widget will bind to the data source specified in the configuration.

> **Info:** Setting the `autoBind` option to `false` is useful in scenarios where multiple widgets are bound to the same data source. Disabling automatic binding would ensure that the shared data source doesn't make more than one request to the remote service.

#### Example - disable automatic binding

    <div id="grid"></div>
    <script>
    var dataSource = new kendo.data.DataSource({
      data: [ { name: "Jane Doe" }, { name: "John Doe" }]
    });
    $("#grid").kendoGrid({
      autoBind: false,
      dataSource: dataSource
    });
    dataSource.read(); // "read()" will fire the "change" event of the dataSource and the widget will be bound
    </script>

Each configuration option must be listed. The type of the option is specified in a markdown code block. The type is required (the CI build will fail if it is not specified). For a list of all available types, see the end of this document. Specify the default option value (if there is any).

Composite options

Composite options are declared by nesting their members like this:

### columns `Array`

A collection of column objects or collection of strings that represents the name of the fields.

### columns.field `String`

The name of the field to which the column is bound.

First specify the name of the composite option. The type should be set to either Object or Array. Then list the fields using ### sections.

Reusing composite options

Nested configuration settings can be reused by extracting them in an common class.

The class name should end with Options, e.g. FillOptions, StrokeOptions.

For example the Circle.fill and Path.fill share a common FillOptions class.

## Configuration

### fill `kendo.dataviz.drawing.FillOptions`
The fill options of the shape.