gen-esbuild.electron.mjs 731 B

123456789101112131415161718192021222324252627
  1. /**
  2. * Don't touch this file. It will be regenerated by theia build.
  3. * To customize the build process, change ./esbuild.mjs
  4. */
  5. import { problemMatcherPlugin, sourceMapPathsPlugin } from '@theia/bundle-plugin';
  6. import { watch, loader, minify, sourcemap } from './gen-esbuild.browser.mjs';
  7. /**
  8. * @type {import('esbuild').BuildOptions}
  9. */
  10. export const electronOptions = {
  11. entryPoints: {
  12. 'preload': './src-gen/frontend/preload'
  13. },
  14. bundle: true,
  15. outdir: 'lib/frontend',
  16. platform: 'node',
  17. mainFields: ['node', 'module', 'main'],
  18. external: ['electron'],
  19. loader,
  20. minify,
  21. sourcemap,
  22. plugins: [
  23. problemMatcherPlugin(watch, 'electron'),
  24. sourceMapPathsPlugin()
  25. ]
  26. };