Table

A table displays rows of data.

When To Use#

  • To display a collection of structured data.
  • To sort, search, paginate and filter data.
import { NzTableModule } from 'ng-zorro-antd/table';

How To Use#

The Table component is both easy to use and highly customizable.

Highly Customizable#

The nz-table can be used like W3C Standard <table>. Developers can control every part of the table as they wish.

Component Enhancements#

The component in nz-table such as th, td, thead etc. are enhanced. Developers can make the table sortable, filterable, with fixed header, perform server side rendering etc. easily with the provided api.

Data Processing#

The data passed to [nzData] is exported with Template Context after processing (including paging, sorting and filtering). *ngFor can be used to render current page data in table.

<nz-table #basicTable [nzData]="dataSet">
  <thead>
    <tr>
      <th>Name</th>
      <th>Age</th>
      <th>Address</th>
      <th>Action</th>
    </tr>
  </thead>
  <tbody>
    <tr *ngFor="let data of basicTable.data">
      <td>{{data.name}}</td>
      <td>{{data.age}}</td>
      <td>{{data.address}}</td>
      <td>
        <a>Action 一 {{data.name}}</a>
        <nz-divider nzType="vertical"></nz-divider>
        <a>Delete</a>
      </td>
    </tr>
  </tbody>
</nz-table>

Examples

NameAgeAddressAction
John Brown32New York No. 1 Lake ParkAction 一 John BrownDelete
Jim Green42London No. 1 Lake ParkAction 一 Jim GreenDelete
Joe Black32Sidney No. 1 Lake ParkAction 一 Joe BlackDelete
  • 1
  • Simple table with actions.

    expand codeexpand code
    Loading...
    Selected 0 items
    NameAgeAddress
    Edward King 032London, Park Lane no. 0
    Edward King 132London, Park Lane no. 1
    Edward King 232London, Park Lane no. 2
    Edward King 332London, Park Lane no. 3
    Edward King 432London, Park Lane no. 4
    Edward King 532London, Park Lane no. 5
    Edward King 632London, Park Lane no. 6
    Edward King 732London, Park Lane no. 7
    Edward King 832London, Park Lane no. 8
    Edward King 932London, Park Lane no. 9
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 10
  • 10 / page

    Rows can be selectable by making first column as a selectable column, to perform operations and clear selections after selecting some rows, all data strategy should be controlled by the developers.

    expand codeexpand code
    Loading...
    NameAgeAddress
    Edward King 032London, Park Lane no. 0
    Edward King 132London, Park Lane no. 1
    Edward King 232London, Park Lane no. 2
    Edward King 332London, Park Lane no. 3
    Edward King 432London, Park Lane no. 4
    Edward King 532London, Park Lane no. 5
    Edward King 632London, Park Lane no. 6
    Edward King 732London, Park Lane no. 7
    Edward King 832London, Park Lane no. 8
    Edward King 932London, Park Lane no. 9
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 20
  • 10 / page

    Use nzSelections to custom selections.

    expand codeexpand code
    Loading...
    Name Age Address
    Jim Green42London No. 1 Lake Park
    Jim Red32London No. 2 Lake Park
  • 1
  • Filter: Use [nzFilters] to define options of the filter menu, [nzFilterFn] to determine filtered result, and [nzFilterMultiple] to indicate whether it's multiple or single selection, you can enable a filter by default by setting a [nzFilters] object's property: { byDefault: true }.

    Sort: Use [nzSortOrder] to make a column sorted by default, use [nzSortFn] to determine sort result, and [nzSortDirections] to define available sort methods.

    expand codeexpand code
    Loading...
    Name Chinese Score Math Score English Score
    John Brown986070
    Jim Green986689
    Joe Black989070
    Jim Red889989
  • 1
  • 使用 [nzSortPriority] to config the priority of sort columns. Though [nzSortFn] to customize compare function.

    expand codeexpand code
    Loading...
    Name Age Address
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
    Jim Red32London No. 2 Lake Park
  • 1
  • Control sorters and filters by [nzSortOrder] and [nzFilters].

    expand codeexpand code
    Loading...
    NameAgeAddress
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
    Jim Red32London No. 2 Lake Park
  • 1
  • Implement a customized column search example via <nz-filter-trigger>.

    expand codeexpand code
    Loading...
    NameGenderEmail
    Liva Rasmussenfemaleliva.rasmussen@example.com
    Louane Leclercfemalelouane.leclerc@example.com
    Léonard Richardmaleleonard.richard@example.com
    Laurine Perrinfemalelaurine.perrin@example.com
    Concepcion Leonfemaleconcepcion.leon@example.com
    Topias Kauppilamaletopias.kauppila@example.com
    Lisan Rosafemalelisan.rosa@example.com
    Sébastien Bertrandmalesebastien.bertrand@example.com
    Alicia Armstrongfemalealicia.armstrong@example.com
    Hilbrand Teskemalehilbrand.teske@example.com
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 20
  • 10 / page

    This example shows how to fetch and present data from remote server, and how to implement filtering and sorting in server side by sending related parameters to server.

    • Pagination:Set [nzFrontPagination]="false" to disable frontend pagination.
    • Sort:Set [nzSortFn]="true" to enable server sort, if you need multiple sort, set [nzSortPriority]="true".
    • Filter:Pass options to [nzFilters] and set [nzFilterFn]="true" to enable server filter.
    • Params:Get all params from (nzQueryParams), the data structure is
    {
      pageIndex: number;
      pageSize: number;
      sort: Array<{ key: string; value: 'ascend' | 'descend' | null }>;
      filter: Array<{ key: string; value: any | any[] }>;
    }

    Note, this example uses a Mock API that you can look up in Network Console.

    expand codeexpand code
    Loading...

    Middle size table

    NameAgeAddress
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
  • 1
  • Small size table

    NameAgeAddress
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
  • 1
  • Two compacted table size: middle and small, small size is used in Modal only.

    expand codeexpand code
    Loading...
    Header
    NameAgeAddress
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
    Footer
  • 1
  • Header
    NameAgeAddress
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
    Footer
  • 1
  • Add border, title and footer for table.

    expand codeexpand code
    Loading...
    NameAgeAddress
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
  • 1
  • When there's too much information to show and the table can't display all at once.

    expand codeexpand code
    Loading...
    NameAgeHome phoneAddress
    John Brown320571-2209890918889898989New York No. 1 Lake Park
    Jim Green420571-2209833318889898888London No. 1 Lake Park
    Joe Black320575-2209890918900010002Sidney No. 1 Lake Park
    Jim Red1818900010002London No. 2 Lake Park
    Jake White18
  • 1
  • Use colspan and rowspan like W3C standards <table>

    expand codeexpand code
    Loading...
    NameAgeAddress
    John Brown sr.60New York No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park
  • 1
  • Display tree structure data in Table, control the indent width by setting nzIndentSize.

    expand codeexpand code
    Loading...
    NameAgeAddress
    Edward King 032London, Park Lane no. 0
    Edward King 132London, Park Lane no. 1
    Edward King 232London, Park Lane no. 2
    Edward King 332London, Park Lane no. 3
    Edward King 432London, Park Lane no. 4
    Edward King 532London, Park Lane no. 5
    Edward King 632London, Park Lane no. 6
    Edward King 732London, Park Lane no. 7
    Edward King 832London, Park Lane no. 8
    Edward King 932London, Park Lane no. 9
    Edward King 1032London, Park Lane no. 10
    Edward King 1132London, Park Lane no. 11
    Edward King 1232London, Park Lane no. 12
    Edward King 1332London, Park Lane no. 13
    Edward King 1432London, Park Lane no. 14
    Edward King 1532London, Park Lane no. 15
    Edward King 1632London, Park Lane no. 16
    Edward King 1732London, Park Lane no. 17
    Edward King 1832London, Park Lane no. 18
    Edward King 1932London, Park Lane no. 19
    Edward King 2032London, Park Lane no. 20
    Edward King 2132London, Park Lane no. 21
    Edward King 2232London, Park Lane no. 22
    Edward King 2332London, Park Lane no. 23
    Edward King 2432London, Park Lane no. 24
    Edward King 2532London, Park Lane no. 25
    Edward King 2632London, Park Lane no. 26
    Edward King 2732London, Park Lane no. 27
    Edward King 2832London, Park Lane no. 28
    Edward King 2932London, Park Lane no. 29
    Edward King 3032London, Park Lane no. 30
    Edward King 3132London, Park Lane no. 31
    Edward King 3232London, Park Lane no. 32
    Edward King 3332London, Park Lane no. 33
    Edward King 3432London, Park Lane no. 34
    Edward King 3532London, Park Lane no. 35
    Edward King 3632London, Park Lane no. 36
    Edward King 3732London, Park Lane no. 37
    Edward King 3832London, Park Lane no. 38
    Edward King 3932London, Park Lane no. 39
    Edward King 4032London, Park Lane no. 40
    Edward King 4132London, Park Lane no. 41
    Edward King 4232London, Park Lane no. 42
    Edward King 4332London, Park Lane no. 43
    Edward King 4432London, Park Lane no. 44
    Edward King 4532London, Park Lane no. 45
    Edward King 4632London, Park Lane no. 46
    Edward King 4732London, Park Lane no. 47
    Edward King 4832London, Park Lane no. 48
    Edward King 4932London, Park Lane no. 49
  • 1
  • 2
  • Display large amounts of data in scrollable view via set y of [nzScroll], you can specify column width via [nzWidth].

    expand codeexpand code
    Loading...
    Full NameAgeColumn 1Column 2Column 3Column 4Column 5Column 6Column 7Column 8Action
    John Brown32New YorkNew YorkNew YorkNew YorkNew YorkNew YorkNew YorkNew Yorkaction
    Jim Green40LondonLondonLondonLondonLondonLondonLondonLondonaction
  • 1
  • To fix some columns and scroll inside other columns, and you must set [nzScroll].x, [nzLeft] and [nzRight] meanwhile.

    Specify the [nzWidth] of columns if header and cell do not align properly. If specified width is not working or have gutter between columns, please try to leave one column at least without width to fit fluid layout, or make sure no long word to break table layout. A fixed value which is greater than table width for nzScroll.x is recommended. The sum of unfixed columns should not greater than nzScroll.x. Note: We using sticky to implement fixed effect. IE 11 will downgrade to horizontal scroll.

    expand codeexpand code
    Loading...
    Full NameAgeColumn 1Column 2Column 3Column 4Column 5Column 6Column 7Column 8Action
    Edward King 032LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 132LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 232LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 332LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 432LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 532LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 632LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 732LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 832LondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King 932LondonLondonLondonLondonLondonLondonLondonLondonaction
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 10
  • Fixed header and column at the same time, a solution for displaying large amounts of data with long columns.

    Specify the [nzWidth] of columns if header and cell do not align properly. If specified width is not working or have gutter between columns, please try to leave one column at least without width to fit fluid layout, or make sure no long word to break table layout. A fixed value which is greater than table width for nzScroll.x is recommended. The sum of unfixed columns should not greater than nzScroll.x. Note: We using sticky to implement fixed effect. IE 11 will downgrade to horizontal scroll.

    expand codeexpand code
    Loading...
    NameOtherCompanyGender
    AgeAddressCompany AddressCompany Name
    StreetBlock
    BuildingDoor No.
    John Brown1Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown2Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown3Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown4Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown5Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown6Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown7Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown8Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown9Lake ParkC2035Lake Street 42SoftLake CoM
    John Brown10Lake ParkC2035Lake Street 42SoftLake CoM
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 10
  • Group table head with fixed columns.

    expand codeexpand code
    Loading...


    NameAgeAddressAction
    Edward King 0
    32London, Park Lane no. 0Delete
    Edward King 1
    32London, Park Lane no. 1Delete
  • 1
  • Table with editable cells.

    In order to get better performance, all NG-ZORRO's components are running under OnPush mode, this means any mutate to the @Input() data won't trigger change detection, please use immutable way to update array or object.

    User can refer to this example to customize the way of editing forms.

    expand codeexpand code
    Loading...
    NameAgeAddressAction
    Edrward 032London Park no. 0Edit
    Edrward 132London Park no. 1Edit
    Edrward 232London Park no. 2Edit
    Edrward 332London Park no. 3Edit
    Edrward 432London Park no. 4Edit
    Edrward 532London Park no. 5Edit
    Edrward 632London Park no. 6Edit
    Edrward 732London Park no. 7Edit
    Edrward 832London Park no. 8Edit
    Edrward 932London Park no. 9Edit
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 10
  • Table with editable rows.

    In order to get better performance, all NG-ZORRO's components are running under OnPush mode, this means any mutate to the @Input() data won't trigger change detection, please use immutable way to update array or object.

    User can refer to this example to customize the way of editing forms.

    expand codeexpand code
    Loading...
    NamePlatformVersionUpgradedCreatorDateAction
    ScreemiOS10.3.4.5654500Jack2014-12-24 23:12:00Publish
    ScreemiOS10.3.4.5654500Jack2014-12-24 23:12:00Publish
    ScreemiOS10.3.4.5654500Jack2014-12-24 23:12:00Publish
  • 1
  • Showing more detailed info of every row.

    expand codeexpand code
    Loading...


    Full NameAgeIndexColumn 1Column 2Column 3Column 4Column 5Column 6Column 7Column 8Action

    Virtual scrolling combine with cdk scrolling used to display large data, you can get cdkVirtualScrollViewport in NzTableComponent and find more API here.

    expand codeexpand code
    Loading...
    NameAgeAddress
    John Brown32New York No. 1 Lake Park
    Jim Green42London No. 1 Lake Park
    Joe Black32Sidney No. 1 Lake Park

    By using custom components, we can integrate table with @angular/cdk/drag-drop to implement drag sorting.

    Note: Need to import {DragDropModule} from '@angular/cdk/drag-drop';

    expand codeexpand code
    Loading...
    CompanyContactCountry
    Alfreds FutterkisteMaria AndersGermany
    Centro comercial MoctezumaFrancisco ChangMexico
    Ernst HandelRoland MendelAustria
    Island TradingHelen BennettUK
    Laughing Bacchus WinecellarsYoshi TannamuriCanada
    Magazzini Alimentari RiunitiGiovanni RovelliItaly

    Template mode, same usage as table, there is no need to data to nzData.

    expand codeexpand code
    Loading...
    Full NameAgeColumn 1Column 2Column 3Column 4Column 5Column 6Column 7Column 8Action
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonaction
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 10
  • Insert line breaks within words with nzBreakWord to prevent text from overflowing its content box

    expand codeexpand code
    Loading...
    Full NameAgeColumn 1Column 2Column ColumnColumn 3Column 4
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondon
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondon
    Edward King32LondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondonLondon
  • 1
  • Ellipsis cell content via setting nzEllipsis and nzTableLayout="fixed".

    can not working with sorter and filters for now

    expand codeexpand code
    Loading...
    Here is Title
    NameAgeAddressAction
    John Brown12New York No. 1 Lake ParkDeleteMore action
    John Brown22New York No. 2 Lake ParkDeleteMore action
    John Brown32New York No. 3 Lake ParkDeleteMore action
    John Brown42New York No. 4 Lake ParkDeleteMore action
    John Brown52New York No. 5 Lake ParkDeleteMore action
    John Brown62New York No. 6 Lake ParkDeleteMore action
    John Brown72New York No. 7 Lake ParkDeleteMore action
    John Brown82New York No. 8 Lake ParkDeleteMore action
    John Brown92New York No. 9 Lake ParkDeleteMore action
    John Brown102New York No. 10 Lake ParkDeleteMore action
    Here is Footer
  • 1
  • 2
  • 3
  • 4
  • 5
  • •••
  • 10
  • Select different settings to see the result.

    expand codeexpand code
    Loading...

    API#

    nz-table#

    PropertyDescriptionTypeDefaultGlobal Config
    [nzData]Data record array to be renderedT[]-
    [nzFrontPagination]Whether to paginate data on client. Should be set to false if data is to be paginated on server side or if all the data is to be displayed at once in the table without any paginationbooleantrue
    [nzTotal]Total data count. Should set when nzServerRender is truenumber-
    [nzPageIndex]pageIndex , double bindingnumber-
    [nzPageSize]pageSize, double bindingnumber-
    [nzShowPagination]Whether to show pagination component at bottom of the tablebooleantrue
    [nzPaginationPosition]Specify the position of pagination'top' | 'bottom' | 'both'bottom
    [nzPaginationType]Specify the size of pagination'default' | 'small'default
    [nzBordered]Whether to show all table bordersbooleanfalse
    [nzOuterBordered]Whether to show table outer bordersbooleanfalse-
    [nzWidthConfig]Set col width can not used with [nzWidth] of thstring[][]
    [nzSize]Size of table'middle' | 'small' | 'default''default'
    [nzLoading]Loading status of tablebooleanfalse
    [nzLoadingIndicator]The loading indicatorTemplateRef<void>-
    [nzLoadingDelay]Specifies a delay in milliseconds for loading state (prevents flush)number0
    [nzScroll]Whether table can be scrolled in x/y direction. x or y can be a string that indicates the width and height of table bodyobject-
    [nzTitle]Table title rendererstring | TemplateRef<void>-
    [nzFooter]Table footer rendererstring | TemplateRef<void>-
    [nzNoResult]Custom no result contentstring | TemplateRef<void>-
    [nzPageSizeOptions]Specify the sizeChanger optionsnumber[][10, 20, 30, 40]
    [nzShowQuickJumper]Determine whether you can jump to pages directlybooleanfalse
    [nzShowSizeChanger]Determine whether nzPageSize can be changedbooleanfalse
    [nzShowTotal]To display Pagination total number and range, same as PaginationTemplateRef<{ $implicit: number, range: [ number, number ] }>-
    [nzItemRender]To customize Pagination item, same as PaginationTemplateRef<{ $implicit: 'page' | 'prev' | 'next', page: number }>-
    [nzHideOnSinglePage]Whether to hide pagination on single pagebooleanfalse
    [nzSimple]Whether to use simple modeboolean-
    [nzTemplateMode]Template mode,no need to pass data to nzDatabooleanfalse
    [nzVirtualItemSize]The size of the items in the list, same as cdk itemSizenumber0
    [nzVirtualMaxBufferPx]The number of pixels worth of buffer to render for when rendering new items, same as cdk maxBufferPxnumber200
    [nzVirtualMinBufferPx]The minimum amount of buffer rendered beyond the viewport (in pixels),same as cdk minBufferPxnumber100
    [nzVirtualForTrackBy]The TrackByFunction to be used for tracking changes.TrackByFunction<T>-
    (nzPageIndexChange)Callback when pageIndex changesEventEmitter<number>-
    (nzPageSizeChange)Callback when pageSize changesEventEmitter<number>-
    (nzCurrentPageDataChange)Callback when current pageData changesEventEmitter<T[]>-
    (nzQueryParams)Callback with params when working with server side pagination, sorting and filteringEventEmitter<NzTableQueryParams>-

    th#

    Checkbox property

    PropertyDescriptionTypeDefault
    [nzShowCheckbox]Whether nz-checkbox should be shown in the headerboolean-
    [nzDisabled]Whether the nz-checkbox is disabledboolean-
    [nzIndeterminate]nz-checkbox indeterminate statusboolean-
    [nzChecked]Checked status, double bindingboolean-
    (nzCheckedChange)Callback when checked status changesEventEmitter<boolean>-

    Selection property

    PropertyDescriptionTypeDefault
    [nzShowRowSelection]Whether to show row selection optionsboolean-
    [nzSelections]Selection options including text and onSelect callback functionArray<{ text: string, onSelect: any }>-

    Sort property

    PropertyDescriptionTypeDefault
    [nzSortFn]Sort function used to sort the data on client side (ref to Array.sort compareFunction). Should be set to true when using server side sortingNzTableSortFn<T> | boolean-
    [nzSortOrder]Sort direction'ascend' | 'descend' | null-
    [nzSortDirections]Supported sort order, could be 'ascend', 'descend', nullArray<'ascend' | 'descend' | null>['ascend', 'descend', null]
    (nzSortOrderChange)Callback when sort direction changesEventEmitter<'ascend' | 'descend' | null>-

    Filter property

    PropertyDescriptionTypeDefault
    [nzShowFilter]Whether to show filterboolean-
    [nzFilterFn]Filter function used to filter the data on client side. Set to true when using server side filteringNzTableFilterFn<T> | boolean-
    [nzFilters]Filter options, text, and value for callback, byDefault to enable filter by defaultArray<{ text: string; value: any; byDefault?: boolean }>-
    [nzFilterMultiple]Whether multiple mode filtering is enabledbooleantrue
    (nzFilterChange)Callback when filter value changesEventEmitter<any[] | any>-

    Style property

    PropertyDescriptionTypeDefault
    [nzWidth]Specify the column width (in pixels), can not used when grouping columnsstring-
    [nzLeft]Left pixels, used to fixed column to left, auto calc when set to true and disable fixed when falsestring | boolean-
    [nzRight]Right pixels, used to fixed column to right, auto calc when set to true and disable fixed when falsestring | boolean-
    [nzAlign]Specify how content is aligned'left' | 'right' | 'center'-
    [nzBreakWord]Whether insert line breaks within wordsbooleanfalse
    [nzEllipsis]ellipsis cell content, not working with sorter and filters for now. Only work when nzTableLayout was fixedbooleanfalse

    Other

    PropertyDescriptionTypeDefault
    [nzColumnKey]column key, work with server sort and filterstring-

    td#

    Checkbox property

    PropertyDescriptionTypeDefault
    [nzShowCheckbox]Whether add nz-checkboxboolean-
    [nzDisabled]Whether disable checkboxboolean-
    [nzIndeterminate]Indeterminate statusboolean-
    [nzChecked]Checked status, double bindingboolean-
    (nzCheckedChange)Checked status change callbackEventEmitter<boolean>-
    [colSpan]how many columns the cell extendsnumbernull
    [rowSpan]how many rows the cell extendsnumbernull

    Expand property

    PropertyDescriptionTypeDefault
    [nzShowExpand]Whether show expand iconboolean-
    [nzExpand]Current expand status, double bindingboolean-
    (nzExpandChange)Expand status change callbackEventEmitter<boolean>-

    Style property

    PropertyDescriptionTypeDefault
    [nzLeft]Left pixels, used to fixed column to left, auto calc when set to true and disable fixed when falsestring | boolean-
    [nzRight]Right pixels, used to fixed column to right, auto calc when set to true and disable fixed when falsestring | boolean-
    [nzAlign]Specify how content is aligned'left' | 'right' | 'center'-
    [nzBreakWord]Whether insert line breaks within wordsbooleanfalse
    [nzEllipsis]ellipsis cell content, not working with sorter and filters for now. Only work when nzTableLayout was fixedbooleanfalse

    Other property

    PropertyDescriptionTypeDefault
    [nzIndentSize]Indent size in pixels of tree datanumber-

    tr#

    PropertyDescriptionTypeDefault
    [nzExpand]Whether expand current row,used with nzExpand of tdboolean-

    nz-filter-trigger#

    Customized filter panel

    PropertyDescriptionTypeDefault
    [nzDropdownMenu]Dropdown menuNzDropdownMenuComponent-
    [nzVisible]whether the dropdown menu is visible, double bindingboolean-
    [nzActive]whether the icon status is activatedbooleanfalse
    [nzHasBackdrop]Whether or not attach a backdrop.booleanfalse
    (nzVisibleChange)a callback function takes an argument: nzVisible, is executed when the visible state is changedEventEmitter<boolean>-

    [nz-virtual-scroll]#

    virtual scroll directive work with ng-template, type: TemplateRef<{ $implicit: T, index: number }>.

    Note#

    In order to get better performance, all NG-ZORRO's components are running under OnPush mode, this means any mutate to the @Input() data won't trigger change detection, please use immutable way to update array or object.

        // add data
        this.dataSet = [ ...this.dataSet, {
          key    : `${this.i}`,
          name   : `Edward King ${this.i}`,
          age    : '32',
          address: `London, Park Lane no. ${this.i}`
        }];
        // remove data
        this.dataSet = this.dataSet.filter(d => d.key !== i);

    Recommend using immer for a better development experience