為專案選擇合適的 IronPDF 版本
我注意到 IronPDF 有幾個不同版本。 我該如何知道哪一個最適合我?
為避免依賴項缺失的問題,不建議使用 IronPdf.Slim。 然而,當目標作業系統不明時,IronPdf.Slim 將展現極高的實用性。 若要在執行時下載 Windows、Linux 或 macOS 的依賴項,必須將 IronPdf.Installation.AutomaticallyDownloadNativeBinaries 設定為 true。
請注意,IronPdf.Slim 除了具備可攜性外,並不會在執行時為使用者節省任何空間。IronPDF 依賴兩項套件:IronPdf.Slim(包含 IronPdf.dll)以及 IronPdf.Native.Chrome(包含 Chrome(預設)渲染器),具體取決於平台。 例如,在 Windows 環境的執行階段,系統將下載 IronPdf.Native.Chrome.Windows。 在 Linux 系統中,將下載 IronPdf.Native.Chrome.Linux;至於 macOS 系統,則會根據所使用的處理器類型,下載 IronPdf.Native.Chrome.MacOS 或 IronPdf.Native.Chrome.MacOS.ARM。
IronPDF
https://www.nuget.org/packages/IronPdf/
- 包含 Chrome(預設)渲染器的 Windows 專屬依賴項
- 預設套件,將在執行時下載 Windows 專屬的依賴項
- 預設使用 Chrome 渲染引擎
- 支援所有平台,但 Windows 平台無需額外下載即可運作
- 適用於 Windows 使用者或一般使用者。 適用於所有平台
IronPdf.Slim
https://www.nuget.org/packages/IronPdf.Slim/
- 不包含 Windows、Linux 或 macOS 的特定依賴項
- Windows、Linux 或 macOS 的依賴項將於執行時自動下載
- 除非另有指定,否則所有平台預設皆使用 Chrome 渲染器
- 適用於希望在執行時下載平台特定依賴項的跨平台解決方案
- 支援所有平台,但平台專屬的依賴項將在首次執行程式時下載
- 適用於 AWS Lambda 或目標平台未知的高度可移植應用程式
-
安裝說明:
- 將
AutomaticallyDownloadNativeBinaries設定為true。 (API 參考) 這將使 Windows、Linux 或 macOS 的依賴項能在執行時下載。
// Enable automatic downloading of platform-specific dependencies IronPdf.Installation.AutomaticallyDownloadNativeBinaries = true;// Enable automatic downloading of platform-specific dependencies IronPdf.Installation.AutomaticallyDownloadNativeBinaries = true;' Enable automatic downloading of platform-specific dependencies IronPdf.Installation.AutomaticallyDownloadNativeBinaries = True$vbLabelText $csharpLabel - 將
IronPdf.Linux
https://www.nuget.org/packages/IronPdf.Linux/
- 包含 Chrome(預設)渲染器的 Linux 專用依賴項
- 預設使用 Chrome 渲染引擎
- 支援所有平台,但 Linux 平台無需額外下載即可運作
- 適用於 Linux 進階使用者,特別是 Docker 和雲端使用者
IronPdf.macOS
https://www.nuget.org/packages/IronPdf.macOS/
- 包含 Chrome(預設)渲染器的 Mac 專用依賴項
- 預設使用 Chrome 渲染引擎
- 適用於 macOS 開發者
IronPdf.Classic
https://www.nuget.org/packages/IronPdf.Classic/
- 內含 IronPdf.Slim 及 IronPdf.Native.WebKit.*
- 包含 (舊版) WebKit 渲染器的 Windows、Linux 及 Mac 依賴項
- 預設使用 WebKit 渲染引擎

