Docs
API
  • format

    Mixed

    Column formatting.

    Values: 'number', 'date'.

    Example

    
    ...
    columns: [{
      title: 'Country',
      index: 'country',
      type: 'string',
      align: 'left',
      cellAlign: 'left'
    },{
      title: 'GDP',
      index: 'gdp',
      width: 60,
      format: 'number'
    ...
    

    Example

    
    ...
    columns: [{
      title: 'Birthday',
      index: 'birthday',
      type: 'date',
      format: {
        read: 'm/d/Y',
        write: 'Y.m.d',
        edit: 'd.m.Y'
      },
      
    ...
    

    Example: SQL Date format

    
    ...
    columns: [{
      title: 'Birthday',
      index: 'birthday',
      type: 'date',
      format: {
        mode: 'sql',
        read: 'YYYY-mm-dd',
        write: 'YYYY-mm-dd',
        edit: 'YYYY-mm-dd'
      },
      
    ...