import type * as esbuild from 'esbuild' ; import { run } from '../build' ; /**
 * Triggers the TypeScript compiler.
 */ export const tscPlugin = { name : 'tscPlugin' , setup ( build ) { const options = build . initialOptions ; if ( process . env . DEV === 'true' ) return ; build . onStart ( async ( ) => { await run ( `tsc --build ${ options . tsconfig }` ) ; } ) ; } , } ;