Jan 14 · 4 min read · Lets Understand what is nodenext and esnext which you usually find in tsconfig.json but don't know what these options actually does. Before that you must have a basic understanding of esm and cjs. In .js file if something is being exported, it become...
Join discussionNov 8, 2025 · 5 min read · 프론트엔드 프로젝트가 대형화될수록 빌드 결과물의 크기가 점차 증가하는 것은 자연스러운 현상입니다.기능의 확장과 라이브러리의 누적 사용으로 인해 번들 사이즈(Bundle Size) 가 커지게 되며, 이는 로딩 속도 및 사용자 경험 저하로 직결됩니다. 그러나 실제로 애플리케이션이 사용하는 코드는 전체 의존성의 일부에 불과합니다.이때 사용되지 않는 코드를 제거하여 번들을 경량화하는 과정을 수행하는 기술이 바로 Tree Shaking입니다.현대의 번들...
Join discussionOct 18, 2025 · 3 min read · 1. 什么是 Rollup 与 ESM? Rollup 基础概念 Rollup 是一种专注于 ES 模块(ESM)的 JavaScript 打包工具。它通过静态分析模块之间的依赖关系,实现极致的 Tree Shaking ,能够在最终产物中剔除未使用的代码,从而大幅度降低 bundle 大小。Rollup 最早用于库级别的打包,如 lodash、moment 等,因其生成的 iife、esm、cjs 等多种格式的兼容性而广受欢迎。 ESM 基础概念 ESM(ECMAScript Modules)...
Join discussionOct 11, 2025 · 3 min read · What is ESM? ESM stands for ECMAScript Modules, which is the official standard for modular JavaScript defined in the ECMAScript specification (ES6/ES2015 and later). ESM allows you to split JavaScript code into separate files (modules) that can imp...
Join discussionJul 9, 2025 · 3 min read · Why Packaging Still Breaks in 2025? Despite being two decades into Node.js, publishing a library that works across CommonJS (CJS), ECMAScript Modules (ESM), TypeScript, and bundlers is still confusing. Why? Because: Node.js evolved from CJS to ESM g...
Join discussion
May 31, 2025 · 3 min read · Dalam dunia JavaScript modern, banyak developer pemula bingung: harus mulai dari mana? Haruskah memahami dulu CommonJS (CJS), ECMAScript Modules (ESM), atau langsung loncat ke TypeScript? Jawabannya mungkin mengejutkan: Fokuslah dulu ke TypeScript. ...
Join discussion
May 7, 2025 · 6 min read · As JavaScript evolves, ECMAScript Modules (ESM) have become the modern standard for writing modular code. ESM supports native imports in browsers, allows for asynchronous loading, and enables better tree-shaking during bundling. If you're transitioni...
Join discussion
Apr 17, 2025 · 4 min read · Recently, while writing unit tests for our React application, I stumbled into one of those classic "wait... what just happened?" developer moments. Everything was going great, and then — boom 💥 — my npm run test exploded with this beauty: SyntaxErro...
Join discussion
Mar 11, 2025 · 6 min read · 최근 팀에서 개발한 디자인 시스템 라이브러리를 프로젝트에 적용하고 사용하면서 흥미로운 문제를 발견했다.(사실 전부터 알고있었지만 잠깐 미뤄뒀다.) 단순히 Button 컴포넌트 하나만 필요했는데, 번들 분석 도구를 확인해보니 라이브러리 전체가 번들에 포함되어 있었던 것이다. 단 하나의 컴포넌트를 위해 수백 KB의 코드가 추가되어버린 것.. // 예상: Button 컴포넌트만 가져오기 import { Button } from '@company/de...
Join discussion