/* eslint-disable n/no-unpublished-import */
+import os from 'os';
+
import json from '@rollup/plugin-json';
import terser from '@rollup/plugin-terser';
import typescript from '@rollup/plugin-typescript';
{
dir: 'dist',
format: 'esm',
- exports: 'auto',
- ...(isDevelopmentBuild && { sourcemap: true }),
- ...(!isDevelopmentBuild && { plugins: [terser({ maxWorkers: 2 })] }),
+ sourcemap: !!isDevelopmentBuild,
+ plugins: [terser({ maxWorkers: os.cpus().length / 2 })],
},
],
external: [