[更新]简单的官方demo井字棋
This commit is contained in:
32
留一个备份的src/List.js
Normal file
32
留一个备份的src/List.js
Normal file
@@ -0,0 +1,32 @@
|
||||
|
||||
/**
|
||||
* Web唐明明
|
||||
* 匆匆数载恍如梦,岁月迢迢华发增。
|
||||
* 碌碌无为枉半生,一朝惊醒万事空。
|
||||
* ComponentName: '列表'
|
||||
*/
|
||||
|
||||
import React from "react"
|
||||
|
||||
class List extends React.Component {
|
||||
render() {
|
||||
return (
|
||||
<div>
|
||||
<h3>{ this.props.title || '是一个列表内容' }</h3>
|
||||
<ul>
|
||||
{
|
||||
this.props.listArr.map((item, key) => {
|
||||
return (
|
||||
<li key={key}>
|
||||
{item.title}
|
||||
</li>
|
||||
)
|
||||
})
|
||||
}
|
||||
</ul>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
export default List
|
||||
Reference in New Issue
Block a user