Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rc-table

Package Overview
Dependencies
Maintainers
2
Versions
440
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rc-table - npm Package Compare versions

Comparing version 2.1.1 to 2.2.0

8

lib/Table.js

@@ -70,3 +70,3 @@ 'use strict';

'td',
null,
{ key: col.key },
text

@@ -105,3 +105,3 @@ ));

var col = columns[i];
rst.push(React.createElement(TableColumn, { title: col.title, dataIndex: col.dataIndex, width: col.width }));
rst.push(React.createElement(TableColumn, { title: col.title, dataIndex: col.dataIndex, width: col.width, key: col.key }));
}

@@ -118,5 +118,7 @@ return rst;

var keyFn = this.props.rowKey;
for (var i = 0; i < data.length; i++) {
var record = data[i];
rst.push(React.createElement(TableRow, { record: record, index: i, columns: columns }));
var key = keyFn ? keyFn(record, i) : undefined;
rst.push(React.createElement(TableRow, { record: record, index: i, columns: columns, key: key }));
}

@@ -123,0 +125,0 @@ return rst;

{
"name": "rc-table",
"version": "2.1.1",
"version": "2.2.0",
"description": "table ui component for react",

@@ -5,0 +5,0 @@ "keywords": [

@@ -41,3 +41,3 @@ # rc-table

online example: http://react-component.github.io/table/build/examples/
online example: http://react-component.github.io/table/examples/

@@ -69,5 +69,11 @@ ## Usage

#### columns
#### rowKey
`Function(recode):string`
* get key value of each row from each row record data
#### columns
* The columns config of table
* key : key of this column
* title : The title of column

@@ -94,2 +100,2 @@ * dataIndex : display the data field

rc-table is released under the MIT license.
rc-table is released under the MIT license.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc