Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Come and chat with us on [Discussions](https://github.com/module-federation/univ

Please read the [Contributing Guide](https://github.com/module-federation/core/blob/main/CONTRIBUTING.md).

![Alt](https://repobeats.axiom.co/api/embed/856dc1d4a6965d225232b1bd2da5d54549dc169e.svg "Repobeats analytics image")
![Alt](https://repobeats.axiom.co/api/embed/856dc1d4a6965d225232b1bd2da5d54549dc169e.svg 'Repobeats analytics image')

## 🙌 Code of Conduct

Expand Down
5 changes: 5 additions & 0 deletions apps/website-new/docs/en/guide/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
"name": "framework",
"label": "Frameworks"
},
{
"type": "dir",
"name": "deployment",
"label": "Deployment"
},
{
"type": "dir",
"name": "debug",
Expand Down
3 changes: 3 additions & 0 deletions apps/website-new/docs/en/guide/deployment/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[
"zephyr"
]
41 changes: 41 additions & 0 deletions apps/website-new/docs/en/guide/deployment/zephyr.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Deploy with Zephyr Cloud

[Zephyr Cloud](https://zephyr-cloud.io) is a zero-config deployment platform that integrates directly into your build process and provides global edge distribution for Module Federation applications.

#### How to deploy

1. Install the Zephyr plugin for your bundler (supports Webpack, Rspack, Vite, etc...):

import InstallKit from '@components/common/install-kit';

<InstallKit
pkgName="zephyr-webpack-plugin"
/>

2. Add the plugin to your webpack configuration:

```javascript title='webpack.config.js'
import { withZephyr } from 'zephyr-webpack-plugin';
const {
ModuleFederationPlugin,
} = require('@module-federation/enhanced/webpack');
const mfConfig = require('./module-federation.config');

module.exports = withZephyr()({
devServer: {
port: 2000,
},
output: {
publicPath: 'http://localhost:2000/',
},
plugins: [new ModuleFederationPlugin(mfConfig)],
});
```

3. Build your project as usual:

```bash
npm run build
```

During the build process, your Module Federation application will be automatically deployed to Zephyr's global edge network and you'll receive a deployment URL. Zephyr Cloud handles asset optimization, dependency resolution, and provides automatic rollback capabilities for your micro-frontend applications.
5 changes: 5 additions & 0 deletions apps/website-new/docs/zh/guide/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
"name": "framework",
"label": "框架"
},
{
"type": "dir",
"name": "deployment",
"label": "部署"
},
{
"type":"dir",
"name":"debug",
Expand Down
3 changes: 3 additions & 0 deletions apps/website-new/docs/zh/guide/deployment/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[
"zephyr"
]
41 changes: 41 additions & 0 deletions apps/website-new/docs/zh/guide/deployment/zephyr.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# 使用 Zephyr Cloud 部署

[Zephyr Cloud](https://zephyr-cloud.io) 是一个零配置部署平台,直接集成到您的构建流程中,为模块联邦应用程序提供全球边缘分发。

#### 如何部署

1. 为您的打包工具安装 Zephyr 插件(支持 Webpack、Rspack、Vite 等):

import InstallKit from '@components/common/install-kit';

<InstallKit
pkgName="zephyr-webpack-plugin"
/>

2. 将插件添加到您的 webpack 配置中:

```javascript title='webpack.config.js'
import { withZephyr } from 'zephyr-webpack-plugin';
const {
ModuleFederationPlugin,
} = require('@module-federation/enhanced/webpack');
const mfConfig = require('./module-federation.config');

module.exports = withZephyr()({
devServer: {
port: 2000,
},
output: {
publicPath: 'http://localhost:2000/',
},
plugins: [new ModuleFederationPlugin(mfConfig)],
});
```

3. 像往常一样构建您的项目:

```bash
npm run build
```

在构建过程中,您的模块联邦应用程序将自动部署到 Zephyr 的全球边缘网络,您将收到一个部署 URL。Zephyr Cloud 处理资源优化、依赖解析,并为您的微前端应用程序提供自动回滚功能。