Skip to content

Commit

Permalink
fix:doc预览不生效问题
Browse files Browse the repository at this point in the history
  • Loading branch information
wangxue08 committed Mar 27, 2024
1 parent 084fd1b commit 9642136
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/cw/cw_office_sdk/components/cw-doc-preview/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,11 @@ export default {
}
},
mounted() {
this.getData(this.value)
this.getData(this.value.trim())
},
methods: {
async getData(url) {
if (url.startsWith("http")) {
if (typeof url === 'string') {
let buf = await fetch(url).then(r => r.arrayBuffer());
this.docxRender(buf);
}
Expand Down

0 comments on commit 9642136

Please sign in to comment.