faq icon indicating copy to clipboard operation
faq copied to clipboard

Is the js-ipfs Javascript library the equivalent for IPFS of what WebTorrent is to Bittorrent?

Open mayerwin opened this issue 10 years ago • 4 comments

Is the browser-embeddable Javascript library js-ipfs the equivalent for IPFS of what WebTorrent is to Bittorrent? How does fallback work for browsers that do not support WebRTC?

mayerwin avatar Sep 18 '16 12:09 mayerwin

Hi @mayerwin, apologies for taking so long to get back to you, I completely missed this one.

js-ipfs is a full node, not a light client. In its final state it will be able to talk with any node in the network. See a more complete answer here: https://github.com/ipfs/faq/issues/97

daviddias avatar Jan 16 '17 03:01 daviddias

@diasdavid Thanks, I didn't find the answers to the second part of the question though: does js-ipfs make use of WebRTC? If so, is there any fallback to browsers that do not support it to ensure js-ipfs works on all major browsers (Firefox, Chrome, Edge, Safari)?

mayerwin avatar Jan 16 '17 04:01 mayerwin

@mayerwin right! On that part, the simple answer is Yes and Yes 🌐, IPFS uses libp2p, a modular network stack that enables IPFS to use transports like: WebRTC, WebSockets, HTTP, uTP, TCP and QUIC to name a few. However, if no WebRTC is available, it means that the other transport used (namely for the browser it will have to be WebSockets or HTTP), will need to be 'upgraded' to be able to do things like Relay/TURN, but that is also part of the libp2p modular stack. See more here: https://github.com/libp2p/js-libp2p

daviddias avatar Jan 16 '17 04:01 daviddias

This issue has been moved to https://discuss.ipfs.io/t/is-the-js-ipfs-javascript-library-the-equivalent-for-ipfs-of-what-webtorrent-is-to-bittorrent/281.

madavieb avatar May 23 '17 02:05 madavieb