Building for Production
Running the Build
bash
npm run buildThis runs acodez build and produces a production-ready plugin.zip that can be submitted to the Acode Plugin Marketplace.
What Happens During a Build
1. TypeScript compilation (Esbuild, ~30ms)
2. SASS → CSS string (esbuild-sass-plugin)
3. Code minification (Esbuild minifier)
4. Source maps stripped (privacy + smaller output)
5. Icon crushing (Jimp, resized to 256x256)
6. Code obfuscation (if enabled) (javascript-obfuscator)
7. plugin.zip assembled (jszip)Enabling Code Obfuscation
To protect your source code, enable obfuscation in your package.json:
json
{
"acodez": {
"obfuscate": true
}
}When enabled, acodez will run the javascript-obfuscator during the build process with high-strength settings:
- Variable name mangling
- String array encoding
- Control flow flattening
- Dead code injection
WARNING
Obfuscation increases build time by 2–5 seconds depending on your plugin's size. It is only applied during acodez build, never during acodez dev.
Build Output
After a successful build, you will find:
my-plugin/
├── dist/
│ └── main.js ← Compiled, minified, and optionally obfuscated
└── plugin.zip ← Ready to submit to the Acode MarketplaceSubmitting to the Marketplace
Gone are the days of manually uploading zip files! acodez completely manages the deployment lifecycle.
- Ensure you are logged in to the CLI:bash
acodez login - Build and publish your plugin in one step:bash
acodez publish
The CLI will automatically compile your code, compress your assets, build the zip, and push it directly to the Acode.app review queue.