Browse Source

docs(uploader): before-xhr-upload #1725

richard1015 3 years ago
parent
commit
7b645245d7

+ 1 - 1
src/packages/__VUE/uploader/demo.vue

@@ -35,7 +35,7 @@
     <h2>{{ translate('title9') }}</h2>
     <nut-uploader :url="uploadUrl" :data="formData" :headers="formData" :with-credentials="true"></nut-uploader>
     <h2>{{ translate('title13') }}</h2>
-    <nut-uploader :url="uploadUrl" method="put" @before-xhr-upload="beforeXhrUpload"></nut-uploader>
+    <nut-uploader :url="uploadUrl" method="put" :before-xhr-upload="beforeXhrUpload"></nut-uploader>
     <h2>{{ translate('title10') }}</h2>
     <nut-uploader :url="uploadUrl" maximum="5" :auto-upload="false" ref="uploadRef"></nut-uploader>
     <br />

+ 1 - 1
src/packages/__VUE/uploader/doc.en-US.md

@@ -293,7 +293,7 @@ export default {
 ```html
 <!-- When the upload method is put, upload the source file stream directly -->
 <template>
-  <nut-uploader url="https://xxxx" method="put" @before-xhr-upload="beforeXhrUpload"></nut-uploader>
+  <nut-uploader url="https://xxxx" method="put" :before-xhr-upload="beforeXhrUpload"></nut-uploader>
 </template>
 
 <script lang="ts">

+ 1 - 1
src/packages/__VUE/uploader/doc.md

@@ -293,7 +293,7 @@ export default {
 ```html
 <!-- 当上传方式为put时,直接上传源文件file流 -->
 <template>
-  <nut-uploader url="https://xxxx" method="put" @before-xhr-upload="beforeXhrUpload"></nut-uploader>
+  <nut-uploader url="https://xxxx" method="put" :before-xhr-upload="beforeXhrUpload"></nut-uploader>
 </template>
 
 <script lang="ts">

+ 1 - 1
src/packages/__VUE/uploader/doc.taro.md

@@ -82,7 +82,7 @@ app.use(Progress);
 :::demo
 ```html
 <template>
-  <nut-uploader url="https://xxxx" @before-xhr-upload="beforeXhrUpload"></nut-uploader>
+  <nut-uploader url="https://xxxx" :before-xhr-upload="beforeXhrUpload"></nut-uploader>
 </template>
 
 <script lang="ts">

+ 1 - 1
src/sites/mobile-taro/vue/src/dentry/pages/uploader/index.vue

@@ -41,7 +41,7 @@
     <h2>自定义数据 FormData 、 headers </h2>
     <nut-uploader :url="uploadUrl" :data="formData" :headers="formData" :with-credentials="true"></nut-uploader>
     <h2>自定义 Taro.uploadFile 上传方式(before-xhr-upload) </h2>
-    <nut-uploader :url="uploadUrl" @before-xhr-upload="beforeXhrUpload"></nut-uploader>
+    <nut-uploader :url="uploadUrl" :before-xhr-upload="beforeXhrUpload"></nut-uploader>
     <h2>选中文件后,通过按钮手动执行上传 </h2>
     <nut-uploader :url="uploadUrl" maximum="5" :auto-upload="false" ref="uploadRef"></nut-uploader>
     <br />