Bundle JavaScript for GAS¶
Bash
npm run bundle
# or
task bundle
- Bundles TypeScript source directly from
src/index.tsinto a single file using Rollup +@rollup/plugin-typescript. - Output format is IIFE (immediately invoked function expression) for GAS compatibility.
- The bundled file is placed at
gaslamp/gaslamp.bundle.js. - Bundle settings are configured in
rollup.config.js.
Warning: Do not delete the entire
gaslamp/directory. It contains both the bundled file and handwritten GAS scripts. If you need to reset the bundle, delete onlygaslamp/gaslamp.bundle.js.
References¶
rollup.config.js— Rollup bundler configurationpackage.json— npm scripts