14 Aug 20172 minutes to read

To customize the ListView dimensions, Width and Height properties are used.

Refer to the following code examples.

  • HTML
  • <div id="defaultlistview">
                <li data-ej-text="Artwork"></li>
                <li data-ej-text="Abstract"></li>
                <li data-ej-text="2 Acrylic Mediums"></li>
                <li data-ej-text="Creative Acrylic"></li>
                <li data-ej-text="Canvas Art"></li>
                <li data-ej-text="Black white"></li>
                <li data-ej-text="Children"></li>
                <li data-ej-text="Preschool Crafts"></li>
                <li data-ej-text="School-age Crafts"></li>

    Add the following script in your code.

  • /// <reference path="jquery.d.ts" />  
    /// <reference path="ej.web.all.d.ts" />
    module ListComponent {
        $(function () {
            var sample = new ej.ListView($("#defaultlistview"), {
                     width: 300, 
                     height: 600

    Run the code to get the following output