File Plugin 7.0.0 & Device Plugin 2.1.0 已發布!
2022年4月11日
我們很高興宣布,我們剛發布了 cordova-plugin-file
& cordova-plugin-device
的更新!
升級方式
cordova plugin remove cordova-plugin-file
cordova plugin add cordova-plugin-file@7.0.0
cordova plugin remove cordova-plugin-device
cordova plugin add cordova-plugin-device@2.1.0
發布重點
cordova-plugin-file
在 Android 平台上,新增了一個 WebViewAssetLoader
代理處理程式,以支援在使用自訂 scheme 時載入 cdvfile
URL。建議使用 toURL
方法來取得可用的 URL。當應用程式從 http
或 https
協定提供服務時,toURL
將會返回適當的可用的 cdvfile
URL。如果應用程式從 file
協定使用,toURL
將會返回原生的 file
URL。
cordova-plugin-device
已新增 Electron 原生支援。
在 Android 平台上,sdkVersion
屬性現在已包含在 window.device
物件中,並在 getInfo
回應物件中返回。
請在 issues.cordova.io 上回報您發現的任何問題!
變更內容包括
cordova-plugin-file
- GH-519 chore!: 移除舊的平台程式碼和程式碼檢查清理
- GH-517 fix(android): 支援自訂 scheme 的 cdvfile 資源
- GH-516 fix(android): 建立
toURL
覆寫以保留其他平台 - GH-487 fix(android): 在列出外部目錄時請求外部讀取權限
- GH-513 feat(android): 為 cdvfile 新增
WebViewAssetLoader
代理處理程式 - GH-490 chore:
npmrc
- GH-489 fix: 恢復 return 陳述式
- GH-470 fix: 移除測試記錄
- GH-447 fix(browser):
preparing.js
中的錯字 - GH-439 chore: 需要 Android 9
- GH-433 refactor(android): 移除過時的 copyResource 函式
- GH-417 fix(android): 使用傳統儲存空間