feat: 添加对 Farm@1.3+ 版本 Rust 插件的使用说明#163
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
WalkthroughThe documentation for using Rust plugins in Farm was updated in both the English and Chinese guides. The changes introduce and explain a new usage pattern available from version 1.3 onwards, where Rust plugins can be imported and used as functions within the configuration file, similar to JavaScript plugins. The new examples demonstrate how to import a Rust plugin and invoke it with options. No code or API changes were made; only documentation was updated to reflect this new approach. Changes
Poem
Tip ⚡💬 Agentic Chat (Pro Plan, General Availability)
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (2)
⏰ Context from checks skipped due to timeout of 90000ms (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (3)
docs/using-plugins.md (2)
77-88: Align example formatting with existing snippets
The new code block has extra blank lines and inconsistent indentation compared to earlier examples. Consider trimming leading/trailing blank lines and aligning indentation to match surrounding patterns:- ```ts title="farm.config.ts" - import reactPlugin from "@farmfe/plugin-react"; - - export default defineConfig({ - plugins: [ - // Use the function approach to call Rust plugins - reactPlugin({ - // Settings - }) - ], - }); - ``` + ```ts title="farm.config.ts" + import reactPlugin from "@farmfe/plugin-react"; + + export default defineConfig({ + plugins: [ + // Use the function approach to call Rust plugins + reactPlugin({ + // Settings + }) + ] + }); + ```
91-93: Capitalize “Rust” in tip heading
For consistency with other sections, capitalize "Rust" in the tip text:- :::tip - To learn more about rust plugins, see [Rust Plugins](/docs/plugins/official-plugins/overview#rust-plugins) + :::tip + To learn more about Rust plugins, see [Rust Plugins](/docs/plugins/official-plugins/overview#rust-plugins)i18n/zh/docusaurus-plugin-content-docs/current/using-plugins.md (1)
88-88: 统一 “Rust” 大写
为保持与英文文档一致,请将 “rust 插件” 改为 “Rust 插件”:- :::tip - 要了解有关 rust 插件的更多信息,请参阅 [Rust 插件](/docs/plugins/official-plugins/overview#rust-插件) + :::tip + 要了解有关 Rust 插件的更多信息,请参阅 [Rust 插件](/docs/plugins/official-plugins/overview#rust-插件)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
docs/using-plugins.md(1 hunks)i18n/zh/docusaurus-plugin-content-docs/current/using-plugins.md(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: Test deployment
新增
rust plugin在farm@1.3的说明文档Summary by CodeRabbit