All Components

DropDowns Overview

The DropDowns allow you to choose from a predefined list of options.

Basic Usage

The following example demonstrates the DropDownList component in action.

import React from 'react';
import ReactDOM from 'react-dom';

import { DropDownList } from '@progress/kendo-react-dropdowns';

class AppComponent extends React.Component {
    sizes = [ "X-Small", "Small", "Medium", "Large", "X-Large", "2X-Large" ];

    render() {
        return (
            <div>
                <div>T-shirt size:</div>
                <DropDownList data={this.sizes} />
            </div>
        );
    }
}

ReactDOM.render(
    <AppComponent />,
    document.querySelector('my-app')
);

Installation

  1. Download and install the package. Use Node.js v5.0.0 or later.

    npm install --save @progress/kendo-react-dropdowns
  2. Once installed, import the package module.

    // ES2015 module syntax
    import { DropDownList } from '@progress/kendo-react-dropdowns';
    // CommonJS format
    const { DropDownList } = require('@progress/kendo-react-dropdowns');
  3. You are required to install one of the Kendo UI themes for React to style your components. For more information on how to add the styles, refer to the article on getting started.

Dependencies

The DropDowns package requires you to install the following peer dependencies in your application:

  • react
  • react-dom
In this article