You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
sims-hq/apps/store-server/build-server.mjs

15 lines
510 B
JavaScript

import { build } from 'esbuild'
await build({
entryPoints: ['src/server.ts'],
outfile: 'dist/server.cjs',
bundle: true,
platform: 'node',
format: 'cjs',
// Native modules can't be bundled. db.ts imports better-sqlite3-multiple-ciphers (the
// SQLCipher-compatible drop-in — H3 encryption at rest); better-sqlite3 stays externalled
// too in case any transitive path still references it.
external: ['better-sqlite3-multiple-ciphers', 'better-sqlite3'],
})
console.log('store-server built')