API 參考

@univerjs-pro/bases-exchange-client

此 API 頁面目前提供英文內容。程式碼簽名與識別符不隨介面語言變更。

Base import and export client integration for Web SDK.

TypeScript
import { UniverBasesExchangeClientPlugin } from '@univerjs-pro/bases-exchange-client'import {  ExchangeBaseExportMode,  ExchangeBaseFormulaPolicy,  ExchangeBaseImportMode,} from '@univerjs-pro/exchange-client'univer.registerPlugin(UniverBasesExchangeClientPlugin, {  importSourceMode: ExchangeBaseImportMode.AUTO,  importFormulaPolicy: ExchangeBaseFormulaPolicy.CONVERT_THEN_VALUES,  exportStructureMode: ExchangeBaseExportMode.TABLES,  exportFormulaPolicy: ExchangeBaseFormulaPolicy.FAIL,})

IUniverBasesExchangeClientConfig

TypeScript
export interface IUniverBasesExchangeClientConfig {  importSourceMode?: ExchangeBaseImportMode  importFormulaPolicy?: ExchangeBaseFormulaPolicy  exportStructureMode?: ExchangeBaseExportMode  exportFormulaPolicy?: ExchangeBaseFormulaPolicy}

Entry Points

  • Facade: @univerjs-pro/bases-exchange-client/facade

Facade API

TypeScript
import '@univerjs-pro/bases-exchange-client/facade'importBaseToUnitIdAsync(file: File | string): Promise<string | undefined>importBaseToSnapshotAsync(file: File | string): Promise<IBaseSnapshot | undefined>exportBaseByUnitIdAsync(unitId: string, format?: ExchangeFormat, tableId?: string): Promise<File | undefined>exportBaseBySnapshotAsync(snapshot: IBaseSnapshot, format?: ExchangeFormat, tableId?: string): Promise<File | undefined>transformSnapshotJsonToBaseDataAsync(json: ISnapshotBlockJsonResponse): Promise<IBaseSnapshot>transformBaseDataToSnapshotJsonAsync(baseData: IBaseSnapshot): Promise<ISnapshotBlockJson>

你覺得這篇文檔如何?

© 2026 DreamNum Co., Ltd.