Skip to Content
자바스크립트 + 리액트 디자인 패턴
book

자바스크립트 + 리액트 디자인 패턴

by 애디 오스마니(Addy Osmani), 윤창식
August 2024
Beginner to intermediate
384 pages
7h 38m
Korean
Hanbit Media, Inc.
Content preview from 자바스크립트 + 리액트 디자인 패턴
242
자바스크립트 + 리액트 디자인 패턴
에서 가져오기/내보내기
import
/
export
를 사용할 수 있습니다. 이러한 프레임워크에서는
Babel
같은 트랜스파일러를 사용해 가져오기/내보내기 문법을 구버전
Node
.
js
에서도 작동하는
require
()
로 변환할 수 있습니다.
ES6
모듈 문법으로 작성된 라이브러리는
Node
.
js
에서
실행할 경우 내부적으로
CommonJS
로 트랜스파일될 것입니다.
10.3.4
CommonJS
는 브라우저 환경에 적합할까?
일부 개발자들은
CommonJS
가 서버 개발에 더 적합하다고 생각합니다. 이는
ES2015
이전,
AMD
와
CommonJS
중 어떤 방식이 사실상 표준
de
facto
이 되어야 하는지에 대한 논쟁의 주
된 이유 중 하나였습니다.
CommonJS
반대파에서는,
CommonJS
의 많은
API
가 서버 환경
을 위한 기능들을 다루기 때문에 자바스크립트로는 브라우저 수준에서 구현할 수 없다고 주
장하였습니다. 대표적인 예로,
io
,
system
,
js
와 같은
API
들은 그 기능 특성상 구현이 불가
능할 수 있다는 것이었습니다.
그럼에도 모듈이 다양한 환경에서 사용될 수 있는지를 알기 위해서는, 우선
CommonJS
모
듈의 구조를 익히는 게 좋습니다. 클라이언트와 서버 환경 모두에서 사용할 수 있는 모듈에
는 데이터 검증, 변환, 템플릿 엔진 등이 있습니다. 일부 개발자들은 모듈 사용 환경을 기준
으로 포맷을 선택하기도 합니다. 서버 환경에서 사용될 수도 있는 경우에는
CommonJS
를,
그렇지 않다면 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

실전 시계열 분석: 통계와 머신러닝을 활용한 예측 기법

실전 시계열 분석: 통계와 머신러닝을 활용한 예측 기법

박찬성, 에일린 닐슨
클라우드 엔지니어를 위한 97가지 조언

클라우드 엔지니어를 위한 97가지 조언

Emily Freeman, Nathen Harvey, 정기훈(Jung Ki Hun)

Publisher Resources

ISBN: 9791169212571