기본 콘텐츠로 건너뛰기

React 요청(Routing)시 보여주기

npm install react-router-dom

index.js
import { BrowserRouter} from "react-router-dom";
...
<BrowserRouter>
    <App />
</BrowserRouter>

App.js
import { Routes, Route, Link } from 'react-router-dom';
...
<div className="App">
    <nav>
        <Link to="/hello">HELLO</Link> |
        <Link to="/test">TEST</Link>
    </nav>
    <Routes>
        <Route path="/hello" element={<Hello/>} />
        <Route path="/test" element={<Test/>} />
    </Routes>
</div>

이 블로그의 인기 게시물

Grid 정렬

  .container { display : grid ; gap : 22px ; width : 1000px ; grid-template-columns : repeat ( auto-fit , 150px ); margin : auto ; justify-content : center ; } .container {      display : grid ; gap : 22px ; grid-template-columns : repeat ( auto-fit , minmax ( 250px , 1fr )); }

Python 변수

지역 변수 a 전역 변수 밖에서 선언한 변수를 사용할 때 앞에 global 을 붙여준다     global a