An opinionated Babel preset for kyt, the NY Times frontend toolkit. Current stable version is 1.1.21 (last released May 2025). It provides a pre-configured Babel setup for React and TypeScript projects, supporting both ESM and CJS modules. Key differentiators: tightly integrated with kyt for zero-config transpilation, includes presets for environment-specific builds (browser, node), and handles module transforms. Alternatives like @babel/preset-env and @babel/preset-react require manual configuration.
npm install babel-preset-kytVerified import paths — ran on the pinned version, not inferred.
Configures babel-preset-kyt in .babelrc and babel.config.js with environment-specific targets.
Use require() or configure via .babelrc/babel.config.js.
Use nested arrays: "presets": [["babel-preset-kyt", { ... }]]npm install @babel/preset-typescript --save-dev and add to presets array.
npm install babel-preset-kyt --save-dev
Use require() or configure via .babelrc/babel.config.js (CommonJS).
Verify .babelrc or babel.config.js includes 'babel-preset-kyt' in presets array.