diff options
author | Feross Aboukhadijeh <feross@feross.org> | 2015-08-12 13:48:18 +0300 |
---|---|---|
committer | Feross Aboukhadijeh <feross@feross.org> | 2015-08-12 14:05:32 +0300 |
commit | 0483f61d22c104771c6c7ff439cf51afbaf2825a (patch) | |
tree | 792ece20ef1f09f0911d9ce74503135003d31239 | |
parent | 6df524ea0a0b09ec7ca3cc4869d9bbc52b81e138 (diff) |
update readme
-rw-r--r-- | README.md | 22 |
1 files changed, 0 insertions, 22 deletions
@@ -150,28 +150,6 @@ dragDrop('body', function (files) { }) ``` -##### Streaming to an HTML5 video element? Also simple! - -```js -var WebTorrent = require('webtorrent') - -var client = new WebTorrent() -var magnetUri = '...' - -client.add(magnetUri, function (torrent) { - // Got torrent metadata! - console.log('Torrent info hash:', torrent.infoHash) - - // Let's say the first file is a webm (vp8) or mp4 (h264) video... - var file = torrent.files[0] - - // Stream the video! - // Specify a container element (CSS selector or reference to DOM node) - file.appendTo('body') - }) -}) -``` - There are more examples in the [examples](https://github.com/feross/webtorrent/tree/master/examples) folder. ##### Browserify |