Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

webpack+vue #1509

Closed
shijunti19 opened this issue Sep 18, 2018 · 1 comment
Closed

webpack+vue #1509

shijunti19 opened this issue Sep 18, 2018 · 1 comment

Comments

@shijunti19
Copy link

@shijunti19 shijunti19 commented Sep 18, 2018

What version of WebTorrent?
0.102.4
"vue": "^2.5.17"
webpack4
What did you expect to happen?
error
What actually happened?

<template>
  <div id="output">
  </div>
</template>
<script>
let WebTorrent = require('webtorrent')
export default {
  name: 'video_index',
  data() {
    return {
      torrentId: 'https://webtorrent.io/torrents/sintel.torrent'
    }
  },
  mounted() {
    if (WebTorrent.WEBRTC_SUPPORT) {
      console.log('WebRTC is supported')
    } else {
      console.log('不支持')
    }
    var client = new WebTorrent()
    client.on('error', function(err) {
      console.error('ERROR: ' + err.message)
    })
    client.add(this.torrentId, function(torrent) {
      var file = torrent.files.find(function(file) {
        return file.name.endsWith('.mp4')
      })
      file.appendTo('#output')
    })
  }
}
</script>

1

stream_readable.js?571b:854 Uncaught TypeError: Cannot read property 'reading' of undefined
at resume
(_stream_readable.js?571b:854)

node: {
    setImmediate: false,
    process: 'mock',
    dgram: 'empty',
    fs: 'empty',
    net: 'empty',
    tls: 'empty',
    child_process: 'empty'
  },
@DiegoRBaquero

This comment has been minimized.

Copy link
Member

@DiegoRBaquero DiegoRBaquero commented Oct 1, 2018

Must be related to the upgrade of readable stream 3, maybe?

@shijunti19 shijunti19 closed this Oct 4, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Jan 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.