Highlight dat-js compatibility wrt dat-node as a warning
aschrijver opened this issue · comments
I read page https://docs.datproject.org/browser on the first day I encountered and - not knowing Dat - completely missed the relevance of this casual text in the introduction:
Because dat-js uses webrtc, it can only connect to other browser clients. It is not possible for the dat-js library to connect to the UTP and UDP clients used in the Node.js versions.
If I understand correctly there is a fundamental choice to make: either go the browser route, or use Node for the 'full Dat experience'. They are different worlds..
I would highlight this text as a warning so its importance is not missed (e.g. with a yellow background, and starting with Important: ...)
Thanks, feel free to PR an update to that page.
If I understand correctly there is a fundamental choice to make: either go the browser route, or use Node for the 'full Dat experience'. They are different worlds..
It is not quite as silo'd as that. You can use webrtc tools in node, such as https://github.com/mappum/electron-webrtc. That allows node clients to connect to browser based webrtc clients. We can also get peers that proxy between both types of connections going.
In general, we've deprecated most support for webrtc for now. We found the initial connection performance less than stellar. We wanted to focus on solid networking via the node clients first. Once we get websocket and http support fully working, we'll use that for initial connections and then fall back to webrtc when it gets connected.