@utoo/pack
High-performance build tool for the Utoo toolchain, powered by Turbopack .
@utoo/pack is the engine behind the Utoo build system. It leverages the incremental computation power of Turbopack and the performance of Rust to provide a lightning-fast development and build experience.
Key Features
- Extreme Performance - Core bundling logic built with Rust
- Turbopack Powered - Built on top of the same engine that powers Next.js Turbopack
- Webpack Compatibility - Support for consuming
webpack.config.jsto simplify migration - Modern Web Support - Native support for TypeScript, JSX, CSS Modules, Less, Sass, and more
- Extensible Architecture - Support for custom loaders, plugins, and flexible configuration
- Fast HMR - Instant updates during development with optimized Hot Module Replacement
Continue with Quick Start to create a sample project and configure entry files.
Supported Features
@utoo/pack is highly compatible with the Webpack ecosystem while providing better performance.
| Category | Support |
|---|---|
| Entry | name, import, and filename templates |
| Module Rules | Most mainstream Webpack loaders via loader-runner |
| Resolve | Full support for alias and extensions |
| Styles | Less, Sass, PostCSS, CSS Modules |
| Optimization | Code minification, Tree Shaking, Module Concatenation |
| Frameworks | React (styled-jsx, emotion, styled-components) |
| Tools | Bundle Analyzer, Tracing Logs |
Configuration
The bundler can be configured via utoopack.json, utoopack.config.mjs, or the programmatic API.
| Option | Description |
|---|---|
entry | Define your application entry points |
output | Output path, file naming, and asset copying |
module | Custom loaders and module rules |
styles | Less, Sass, CSS Modules, Emotion, styled-components |
optimization | Minification, tree shaking, split chunks, import transforms |
devServer | Host, port, HTTPS, HMR, proxy |
define | Build-time variable replacement |
provider | Auto-provide modules |
externals | Exclude specific dependencies from the bundle |
resolve | Aliases and extension resolution |
persistentCaching | Reuse cache across runs |
mode | development or production |
resolve | Module resolution (alias, extensions) |
module | Custom loader rules |
optimization | Minification, tree shaking, split chunks, and more |
styles | Less, Sass, CSS Modules, Emotion, styled-components |
devServer | Dev server (hot, port, host, https) |
stats | Enable build statistics output |
See Configuration for full details.
Last updated on