Features
The practice of building web applications is enormously diverse. In CSS alone, you have SCSS, Less, CSS Modules, PostCSS, and hundreds of other libraries. Frameworks like React, Vue and Svelte require custom setups.
When building a bundler, we needed to consider which features would be:
- Built-in: they work out of the box, no config required
- Available via plugins: usually installed from a registry and configured
- Unavailable: not available at all
Turbopack is in beta, so very few of these decisions are set in stone. In its current state, Turbopack cannot yet be configured - so plugins are not available yet.
Let's discuss which features are available out-of-the-box, in Turbopack's default configuration. We'll also touch on features which will be configurable via plugins.
JavaScript
Supports all ESNext features, Browserslist and top-level await.
TypeScript
Supports TypeScript out of the box, including resolving paths
and baseUrl
.
Imports
Supports require
, import
, dynamic imports and more.
Dev Server
Our optimized dev server supports Hot Module Reloading (HMR) and Fast Refresh.
CSS
Supports Global CSS, CSS Modules, postcss-nested and @import
.
Frameworks
Learn about Next.js, Svelte, Vue and React Server Components support.
Static Assets
Supports the /public
directory, JSON imports, and importing assets via ESM.
Environment Variables
Supports environment variables via .env
, .env.local
, and more.