ClosedList.js 527 Bytes
Newer Older
우지원's avatar
ul    
우지원 committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import React, { useState } from 'react'
import { ListGroup } from 'react-bootstrap';

function ClosedList() {
  const [list, setList] = useState([
    { room: '테스트 방1', memnum: 5, admin: '가영' },
    { room: '테스트 방2', memnum: 4, admin: '수현' }]
  );
  return (
    <div>
      {list.map((list, index) =>
        <ListGroup key={index}>
          <ListGroup.Item action>
            <h2>{list.room}</h2>
          </ListGroup.Item>
        </ListGroup>
      )}
    </div>
  )
}

export default ClosedList