Google Apps Script does not allow import/export.
Also, generated code by the module bundler cannot be executed (in most cases).
The same was true for esbuild.
So, I created esbuild-gas-plugin.
This plugin provides code generation using gas-entry-generator.
The generated code is executable and import/export can be used!
Sample project is here.