SlideShare a Scribd company logo
1 of 18
Package
Manager
Team Study
2022.07.15
노별마루
npm & Yarn
npm Yarn
Node package Manager
npm
2010
Isaac Z.
Schlueter
2015 2017
npm v1 npm v3 npm v5
2018
npm v6
2020
npm v7
Node package Manager
npm
Node package Manager
npm
Node package Manager
npm
yarn
2016
Facebook
2020 2021
yarn v1 yarn v2 yarn v3
yarn
node_modules
node_modules
Ryan
Lienhart
Dahl
node_modules
Yarn berry
PnP
zero-install
Plugin
system
protocols
ZipFS
workspaces
Thank you

More Related Content

More from Wonjun Hwang

Open AI SORA (키트웍스 팀스터디 발표자료 박준기 240315)
Open AI SORA  (키트웍스 팀스터디 발표자료 박준기 240315)Open AI SORA  (키트웍스 팀스터디 발표자료 박준기 240315)
Open AI SORA (키트웍스 팀스터디 발표자료 박준기 240315)Wonjun Hwang
 
Nest JS (Kitworks Team Study 이본훈 발표 240315)
Nest JS (Kitworks Team Study 이본훈 발표 240315)Nest JS (Kitworks Team Study 이본훈 발표 240315)
Nest JS (Kitworks Team Study 이본훈 발표 240315)Wonjun Hwang
 
JS Event Loop (Kitworks Team Study 김동현 발표)
JS Event Loop (Kitworks Team Study 김동현 발표)JS Event Loop (Kitworks Team Study 김동현 발표)
JS Event Loop (Kitworks Team Study 김동현 발표)Wonjun Hwang
 
Java Optional (Kitworks Team Study 김성호 발표)
Java Optional (Kitworks Team Study 김성호 발표)Java Optional (Kitworks Team Study 김성호 발표)
Java Optional (Kitworks Team Study 김성호 발표)Wonjun Hwang
 
XSS(Cross site scripting) - Kitworks Team Study
XSS(Cross site scripting) - Kitworks Team StudyXSS(Cross site scripting) - Kitworks Team Study
XSS(Cross site scripting) - Kitworks Team StudyWonjun Hwang
 
Flutter & Firebase (2) Kitworks Team Study
Flutter & Firebase (2) Kitworks Team StudyFlutter & Firebase (2) Kitworks Team Study
Flutter & Firebase (2) Kitworks Team StudyWonjun Hwang
 
얕은복사,깊은복사
얕은복사,깊은복사얕은복사,깊은복사
얕은복사,깊은복사Wonjun Hwang
 
Go언어로 디스코드 봇 만들기
Go언어로 디스코드 봇 만들기Go언어로 디스코드 봇 만들기
Go언어로 디스코드 봇 만들기Wonjun Hwang
 
완전 유용한 CSS 모음
완전 유용한 CSS 모음완전 유용한 CSS 모음
완전 유용한 CSS 모음Wonjun Hwang
 
2024 개발 트렌드
2024 개발 트렌드2024 개발 트렌드
2024 개발 트렌드Wonjun Hwang
 
디바운싱과 쓰로틀링
디바운싱과 쓰로틀링디바운싱과 쓰로틀링
디바운싱과 쓰로틀링Wonjun Hwang
 
스마트한 팀 협업
스마트한 팀 협업스마트한 팀 협업
스마트한 팀 협업Wonjun Hwang
 
구름톤 8기 후기
구름톤 8기 후기구름톤 8기 후기
구름톤 8기 후기Wonjun Hwang
 
2024년 키워드로 알아보는 트렌드
2024년 키워드로 알아보는 트렌드2024년 키워드로 알아보는 트렌드
2024년 키워드로 알아보는 트렌드Wonjun Hwang
 
오버라이딩 조금 더 알아보기
오버라이딩 조금 더 알아보기오버라이딩 조금 더 알아보기
오버라이딩 조금 더 알아보기Wonjun Hwang
 

More from Wonjun Hwang (20)

Open AI SORA (키트웍스 팀스터디 발표자료 박준기 240315)
Open AI SORA  (키트웍스 팀스터디 발표자료 박준기 240315)Open AI SORA  (키트웍스 팀스터디 발표자료 박준기 240315)
Open AI SORA (키트웍스 팀스터디 발표자료 박준기 240315)
 
Nest JS (Kitworks Team Study 이본훈 발표 240315)
Nest JS (Kitworks Team Study 이본훈 발표 240315)Nest JS (Kitworks Team Study 이본훈 발표 240315)
Nest JS (Kitworks Team Study 이본훈 발표 240315)
 
JS Event Loop (Kitworks Team Study 김동현 발표)
JS Event Loop (Kitworks Team Study 김동현 발표)JS Event Loop (Kitworks Team Study 김동현 발표)
JS Event Loop (Kitworks Team Study 김동현 발표)
 
Java Optional (Kitworks Team Study 김성호 발표)
Java Optional (Kitworks Team Study 김성호 발표)Java Optional (Kitworks Team Study 김성호 발표)
Java Optional (Kitworks Team Study 김성호 발표)
 
XSS(Cross site scripting) - Kitworks Team Study
XSS(Cross site scripting) - Kitworks Team StudyXSS(Cross site scripting) - Kitworks Team Study
XSS(Cross site scripting) - Kitworks Team Study
 
Flutter & Firebase (2) Kitworks Team Study
Flutter & Firebase (2) Kitworks Team StudyFlutter & Firebase (2) Kitworks Team Study
Flutter & Firebase (2) Kitworks Team Study
 
PWA
PWAPWA
PWA
 
얕은복사,깊은복사
얕은복사,깊은복사얕은복사,깊은복사
얕은복사,깊은복사
 
Go언어로 디스코드 봇 만들기
Go언어로 디스코드 봇 만들기Go언어로 디스코드 봇 만들기
Go언어로 디스코드 봇 만들기
 
완전 유용한 CSS 모음
완전 유용한 CSS 모음완전 유용한 CSS 모음
완전 유용한 CSS 모음
 
2024 개발 트렌드
2024 개발 트렌드2024 개발 트렌드
2024 개발 트렌드
 
디바운싱과 쓰로틀링
디바운싱과 쓰로틀링디바운싱과 쓰로틀링
디바운싱과 쓰로틀링
 
Passkey
PasskeyPasskey
Passkey
 
스마트한 팀 협업
스마트한 팀 협업스마트한 팀 협업
스마트한 팀 협업
 
AI News '23.12
AI News '23.12AI News '23.12
AI News '23.12
 
Google Analytics
Google AnalyticsGoogle Analytics
Google Analytics
 
구름톤 8기 후기
구름톤 8기 후기구름톤 8기 후기
구름톤 8기 후기
 
2024년 키워드로 알아보는 트렌드
2024년 키워드로 알아보는 트렌드2024년 키워드로 알아보는 트렌드
2024년 키워드로 알아보는 트렌드
 
상속과 구현
상속과 구현상속과 구현
상속과 구현
 
오버라이딩 조금 더 알아보기
오버라이딩 조금 더 알아보기오버라이딩 조금 더 알아보기
오버라이딩 조금 더 알아보기
 

Recently uploaded

Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbuapidays
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Zilliz
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfOverkill Security
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 

Recently uploaded (20)

Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 

Editor's Notes

  1. Npm: node package manager Yarn : yet Another Resource negotiator
  2. Npm: 자바스크립트 런타임 환경 node.js의 기본 패키지 관리자 데이터 무결성 검사를 위해 SHA-512를 사용 아이작 z 슐루터 V1: 설치 패키지들의 보안 취약성, 설치 속도 현저히 느림(계층구조..) 또한 윈도우에서는 경로의 길이가 최대260자라서.. 문제됨 V3: 호이스팅(flat하게 한계층으로 설치) V5: package.lock파일 생성 -> yarn과 설치 속도 비슷(아직 느림) V6: 설치한 패키지들의 보얀 취약성을 보완(npm audit등으로 확인) V7: workspace 개념 도입 최상위 package.json에서 { “workspaces:”: [‘test1’, ‘test2’] } 기입하면 test1, test2 폴더구조로 생성됨.
  3. 참고: https://blog.logrocket.com/exploring-workspaces-other-advanced-package-manager-features/ 계층 구조 및 flat 구조 Node.js는 require()를 하는 경우 현재의 node_modules에서 먼저 찾고 없으면 부모 디렉터리로 가면서 계속 node_modules를 찾아서 의존성을 처리하기 때문에 우선순위상 자신의 디렉터리 하위에 있는 것을 먼저 사용하게 된다. V3: 유령 의존성 B npm dedupe 명령어로 중복 의존성 제거
  4. Package.json나 node_modules 트리가 수정될 경우 자동으로 생성. Package-lock.json을 사용하여 node_modules 생성(부족한 정보를 도와주는 파일)
  5. 보안성 취약한 라이브러리를 설치시 경고해줌.
  6. Yarn v2버전 이후부터 yarn2로 명시(berry라는 코드이름) yet Another Resource Negotiator ? V1: yarn.lock 자동생성, 특정 경로에 설치파일 캐시 Npm과 다르게 특별한 선택 알고리즘을 도입하여 의존성 트리가 변형되지 않음. Checksum방식으로 무결성 보장(중복검사의 한 형태) Offline Mode : 이전에 설치했었던 패키지 들은 다시 설치할때는 offline에서도 설치가 가능합니다. Deterministic : 설치 순서에 상관없이 같은 의존성 트리가 생성됩니다. Network Performance : 네트워크 활용을 극도로 하여 큐를 사용하여 네트워크 요청을 효율적으로 관리합니다. Network Resilience : 하나의 요청이 실패해도 전체 설치과정이 실패하지 않습니다. 실패 이후에 재요청 됩니다. Flat Mode : 패키지의 중복 생성을 방지하기 위해 서로 다른 버전의 종속성을 단일 버전으로 해결하였습니다.
  7. Yarn.lock 잠금 파일을 기준으로 설치됨(신규 패키지 설치나 기존 패키지 갱신/제거할때 자동 동기화)
  8. node.js에서는 어떤 모듈을 사용하고자 하면 모듈을 찾기 위해 부모 ~ 루트 까지 node_modules 폴더를 찾는 방식을 사용합니다. 단점 ⇒ 패키지를 찾으려고 Require문을 통한 readdir (I/O 호출이 반복되다보니 런타임에서 느려질 수 있음) Npm이나 yarn이나 똑같음 ㅎㅎ;
  9. Node.js 창시자인 Ryan Dahl의 node.js의 디자인 설계 실수 유령 의존성 현상 발생 개발 협업간 혼란 야기 용량이 너무 커짐..
  10. 태양, 중성자 별, 블랙홀, 그리고.. 노드 모듈
  11. 새로운 전략을 들고 나옴 Plug’n Play(PnP) 방식
  12. Workspaces 여러 프로젝트가 동일한 저장소에서 상호작용이 필요할 경우
  13. .yarn/cache 폴더에 의존성의 정보가 저장 .pnp.cjs파일에 의존성을 찾을 수 있는 정보가 기록 Yml파일에 nodeLinker: node-modules 명시해주면 zip 아카이브가 아닌 node_modules 방식으로 관리한다. Zero-install
  14. Vue 패키지 중에 Npm2.7.5버전은 packageLocation 위치에 있고 packageDependencies에 기입되어있는 의존성들을 참조한다.
  15. 저장소를 복제하거나 브랜치 변경해도 yarn install 필요없음. 버전관리시스템으로 관리!! (git) Zero-install
  16. 다양한 node_modules 타게 방법 Deno(모듈없이) Github package registry(패키지 저장소 호스팅) Pnpm (패키지 매니저)
  17. 즉시시작을 의미 바로가기 할 수 있다는 느낌이다?