瀏覽代碼

docs: Add `target: DOMElement` style to plugin docs

Renée Kooi 7 年之前
父節點
當前提交
a5089cc668
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      website/src/docs/plugins.md

+ 2 - 1
website/src/docs/plugins.md

@@ -22,13 +22,14 @@ Each plugin can have any number of options (please see specific plugin for detai
 
 
 ### `target`
 ### `target`
 
 
-Can be a `string` or an `object`, referencing another plugin. Consider the following example, where `DragDrop` plugin will be rendered into a `body` element:
+Can be a `string` CSS selector, a DOM element, or a Plugin class. Consider the following example, where `DragDrop` plugin will be rendered into a `body` element:
 
 
 ```js
 ```js
 const Uppy = require('uppy/lib/core')
 const Uppy = require('uppy/lib/core')
 const DragDrop = require('uppy/lib/plugins/DragDrop')
 const DragDrop = require('uppy/lib/plugins/DragDrop')
 const uppy = Uppy()
 const uppy = Uppy()
 uppy.use(DragDrop, {target: 'body'})
 uppy.use(DragDrop, {target: 'body'})
+// or: uppy.use(DragDrop, {target: document.body})
 ```
 ```
 
 
 While in this one, we are using the `Dashboard` plugin, which can act as a host target for other plugins:
 While in this one, we are using the `Dashboard` plugin, which can act as a host target for other plugins: