mirror of
https://github.com/napi-rs/napi-rs.git
synced 2025-12-08 19:56:07 +00:00
25 lines
485 B
TypeScript
25 lines
485 B
TypeScript
import { defineConfig } from 'tsdown'
|
|
|
|
export default defineConfig([
|
|
{
|
|
entry: './src/index.ts',
|
|
fixedExtension: false,
|
|
format: ['esm', 'cjs'],
|
|
target: 'node16',
|
|
sourcemap: 'inline',
|
|
inputOptions(options, format) {
|
|
if (format === 'cjs') {
|
|
options.external = ['@octokit/rest']
|
|
}
|
|
return options
|
|
},
|
|
},
|
|
{
|
|
entry: './src/cli.ts',
|
|
sourcemap: 'inline',
|
|
target: 'node16',
|
|
dts: false,
|
|
fixedExtension: false,
|
|
},
|
|
])
|