import type { Plugin } from 'esbuild' ; /**
 * Marks all packages as external.
 */ const externalPlugin = { name : 'externalPlugin' , setup ( build ) { const onlyPackages = /^[^.\/]|^\.[^.\/]|^\.\.[^\/]/ ; build . onResolve ( { filter : onlyPackages } , ( args ) => ( { path : args . path , external : true , } ) ) ; } , } ; export { externalPlugin } ;