-
https://create-react-app.dev/docs/proxying-api-requests-in-development/
Proxying API Requests in Development | Create React App
Note: this feature is available with react-scripts@0.2.3 and higher.
create-react-app.dev
AJAX and APIs
https://reactjs.org/docs/faq-ajax.html
fetch("https://api.example.com/items") .then(res => res.json()) .then( (result) => { this.setState({ isLoaded: true, items: result.items }); }); ...
https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch
Using the Fetch API - Web APIs | MDN
The Fetch API provides a JavaScript interface for accessing and manipulating parts of the protocol, such as requests and responses. It also provides a global fetch() method that provides an easy, logical way to fetch resources asynchronously across the net
developer.mozilla.org
https://velog.io/@daybreak/React-Fetch%ED%95%A8%EC%88%98
[React] Fetch함수
HTML, CSS, Javascript를 이용해서 인스타그램 클론코딩을 마치고, 리액트로 바꾸었다. 이번 작업은 백엔드에게 API받아서 로그인을 할 수 있는 작업을 하였다.fetch함수는 API를 사용하여
velog.io
'React' 카테고리의 다른 글
styled-jsx/css 스타일 적용 (0) 2022.12.23 react-icons (0) 2022.12.23 React Tsx Jsx 반복문 for map (0) 2022.12.20 React HelloWorld Tsx파일 Ex (0) 2022.12.20 NodeJs & Typescript 기반에서 React 배포 (0) 2022.11.20 React 빌드와 테스트 (0) 2022.11.20 React Component setState (0) 2022.11.19 React props 합성 (Composition) Ex (0) 2022.11.19