浏览代码

docs: add sample snippets to ProgressBar docs

Renée Kooi 7 年之前
父节点
当前提交
25b347168a
共有 1 个文件被更改,包括 14 次插入0 次删除
  1. 14 0
      website/src/docs/progressbar.md

+ 14 - 0
website/src/docs/progressbar.md

@@ -11,6 +11,13 @@ ProgressBar is a minimalist plugin that shows the current upload progress in a t
 
 
 ## Options
 ## Options
 
 
+```js
+uppy.use(ProgressBar, {
+  target: '.UploadForm',
+  fixed: false
+})
+```
+
 ### `target: null`
 ### `target: null`
 
 
 DOM element, CSS selector, or plugin to mount the progress bar into.
 DOM element, CSS selector, or plugin to mount the progress bar into.
@@ -18,3 +25,10 @@ DOM element, CSS selector, or plugin to mount the progress bar into.
 ### `fixed: false`
 ### `fixed: false`
 
 
 When true, show the progress bar at the top of the page with `position: fixed`. When false, show the progress bar inline wherever it is mounted.
 When true, show the progress bar at the top of the page with `position: fixed`. When false, show the progress bar inline wherever it is mounted.
+
+```js
+uppy.use(ProgressBar, {
+  target: 'body',
+  fixed: true
+})
+```