summaryrefslogtreecommitdiff
path: root/assets/script/watch.site.js
blob: 9e6af5d0ea4217085b18ffb35964d4ad58b98eec (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
const esbuild = require('esbuild');
const { stimulusPlugin } = require('esbuild-plugin-stimulus');
//site.js --bundle --sourcemap=inline --watch --outfile=assets/site.js

esbuild.build({
  entryPoints: ['site.js'],
  bundle: true,
  outfile: '../priv/static/assets/site.js',
  minify: true,
  sourcemap: "inline",
  watch: true,
  plugins: [stimulusPlugin()],
}).catch(() => process.exit(1));