moduleTypes
- Type:
ModuleTypes - Optional
Defined in: options/input-options.ts:476
Maps file patterns to module types, controlling how files are processed.
This is conceptually similar to esbuild's loader option, allowing you to specify how each file extensions should be handled.
See the In-Depth Guide for more details.
Example
js
import { defineConfig } from 'rolldown'
export default defineConfig({
moduleTypes: {
'.frag': 'text',
}
})