index.js 360 Bytes
Newer Older
duanledexianxianxian's avatar
sync  
duanledexianxianxian committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
import React from 'react';
import Item from './item';

import styles from './index.less';

const Index = ({ dataSource=[]}) => {
  const renderItem = () => {
    return dataSource.map(x => (
      <Item
        {...x}
      />
    ));
  };
  return (
    <div className={styles.root}>
       <div>{renderItem()}</div>
    </div>
  );
};

export default Index;