Rollup plugin for Zephyr
npm install rollup-plugin-zephyrA Rollup plugin for deploying applications with Zephyr Cloud. This plugin enables seamless deployment of your Rollup-built applications to Zephyr's global edge network.
``bashnpm
npm install --save-dev rollup-plugin-zephyr
Usage
Add the plugin to your Rollup configuration:
`javascript
// rollup.config.js
import { zephyrPlugin } from 'rollup-plugin-zephyr';export default {
input: 'src/main.js',
output: {
dir: 'dist',
format: 'es',
},
plugins: [
// ... other plugins
zephyrPlugin(),
],
};
`$3
`javascript
// rollup.config.mjs
import { zephyrPlugin } from 'rollup-plugin-zephyr';export default {
input: 'src/main.js',
output: {
dir: 'dist',
format: 'es',
},
plugins: [
zephyrPlugin({
// Configuration options
}),
],
};
`$3
`typescript
// rollup.config.ts
import { defineConfig } from 'rollup';
import { zephyrPlugin } from 'rollup-plugin-zephyr';export default defineConfig({
input: 'src/main.ts',
output: {
dir: 'dist',
format: 'es',
},
plugins: [zephyrPlugin()],
});
`Features
- 🚀 Automatic deployment during build
- 📦 Asset optimization and bundling
- 🔧 Zero-config setup
- 📊 Build analytics and monitoring
- 🌐 Global CDN distribution
- ⚡ Edge caching and optimization
Getting Started
1. Install the plugin in your Rollup project
2. Add it to your Rollup configuration
3. Build your application as usual with
rollup -c
4. Your app will be automatically deployed to Zephyr CloudBuild Scripts
Add these scripts to your
package.json:`json
{
"scripts": {
"dev": "rollup -c -w",
"build": "rollup -c",
"build:prod": "NODE_ENV=production rollup -c"
}
}
``- Rollup 2.x or higher
- Node.js 14 or higher
- Zephyr Cloud account (sign up at zephyr-cloud.io)
We welcome contributions! Please read our contributing guidelines for more information.
Licensed under the Apache-2.0 License. See LICENSE for more information.