Are you an LLM? You can read better optimized documentation at /plugins/plugin-barrel/recipes/named-re-exports-for-tree-shaking.md for this page in Markdown format
Named re-exports for tree-shaking
Set type to 'named' so each barrel re-exports symbols by name, which keeps imports explicit and bundlers able to tree-shake.
kubb.config.ts
typescript
import { defineConfig } from 'kubb/config'
import { pluginTs } from '@kubb/plugin-ts'
export default defineConfig({
input: './petStore.yaml',
output: { path: './src/gen', clean: true, barrel: { type: 'named' } },
plugins: [pluginTs()],
})