Build a decentralized chat app using the GUN JavaScript library. Learn how to use web3 technology to create a peer-to-peer graph database without traditional cloud computing providers. https://gun-chat-dapp.web.app/
#js #web3 #tutorial
🔗 Resources
Live Demo: https://gun-chat-dapp.web.app/
View on Product Hunt: https://www.producthunt.com/posts/gun-2
Docs: https://gun.eco/
Source Code: https://github.com/fireship-io/gun-chat
📚 Chapters
00:00 Intro
00:56 How it Works
03:11 Setup
03:30 User Authentication
07:43 Chat Messages
🤓 Install the quiz app
iOS https://itunes.apple.com/us/app/fireship/id1462592372?mt=8
Android https://play.google.com/store/apps/details?id=io.fireship.quizapp
🔥 Watch more with Fireship PRO
Upgrade to Fireship PRO at https://fireship.io/pro
Use code lORhwXd2 for 25% off your first payment.
🎨 My Editor Settings
– Atom One Dark
– vscode-icons
– Fira Code Font
Topics Covered
– Pros and Cons of Web3 development
– How to develop decentralized apps
– WebRTC
– End-to-End e2e encryption for chat
– Using Svelte to build a chat UI
50 Comments
GUN author here! Gaaaaah the app is already swamped, OK looks like I'm gonna need to working on my scaling code… trying to fix things now! Probably too late. Please try to run a local version of the project in the meanwhile (so sorry) – and I'm happy to answer any Qs too (tho YouTube rate-limits how fast commenters/me can I reply).
Fireship rocks! You guys deserve maximum success!
I liked the idea of GUN but the docs are not good
I've been your fan for a long time. You do really awesome and useful content and I really appreciate for it. That's sad, it's first time when I must leave dislike on your video. Please next time get rid of any reference to Vladimir Putin, he's disgusting.
thanks in advance
this is the side of programming that I absolutely loath
Cool stuff, bro.
Im really confused with the dapp thing, so if we use whatsapp, only company will be observing our data as our data is stored in their server, if we use dapp chat app then our data will be stored in many computers right, so instead of one person or company our data will be visible to many right so whats the use of decentralised thing here if our data is stored in serveral different computer as part of block chain then its not privacy right, if anyone knows about this explain me please, as far as i know about the blockchain i had this doubt i may be wrong too so correct me if anyone knows
@fireship can u answer my doubt
*fizzle sounds* … meh.
Too much freedom. Will be banned in eu soon.
i see that the db is decentralized but where did you host the app as you said it cost you nothing to run , ive been looking for a decentralised db and hosting solution
you are aweasome! built a chat app in 10 minutes
What I noticed:
1. You need to update the page, otherwise nicknames are marked UN
2. It's so slow…
What's the advantage of this over IRC? It sounds similar.
do a video hypercore protocol pleeeeaaaaseee?
Very Cool.
damn it i'm too slow
i got some sort idea of a torrent based chat client
But can user who has a piece of your information see it?
Please do more web3 specific content.
A few things when you called login you didn’t pass any variables user/pass maybe they’re in state idk. Also when you set messages you threw a spread operator on there with a minus 100 are you only showing the last 100 messages in the buffer? Great video it was a little fast but better than those slow ones 😛
This sounds a suspicious amount like torrents, and it looks like there have already been/are torrent-based chat services
@fireship, when its a decentralized chat app there shouldn't be any signin or signup?
Oh gawd… the format structure of Javascript is almost confusing for a budding Noobie Coder like me. I kinda understand. As a proof of concept. It's fucking neat. ✨👍
I want to know more about relay server
what if our required peer destroyed, where will it's data gown, and is this will be not a very big flaw?
does these decentralized apps does not have a major breaking point of lack of resources to store data on local user's device? like for this scenario, after 1 year usage of both types of chatapp, whatsapp consumes very less amount of resources of user's device as compare to decentralized chatapp? am i right? if yes then how these decentralized apps can beneficial for us?
Sir, when I cloned, it does not work properly. it is not like your demo link. no message area to type…even some errors exist
Hey can I use this for my personal project ? If yes please let me know how can I use this 🙂 Your's lovingly uncle ben
Sponsored by Marc Benioff / WEF
Can GUN be used with python?
Video is about gun and it is like a bullet. To the point and fast. Nice work.
Yikes. Putin GIF did not age well. Even at the time, it was riding the line between just "edgy" and gross.
hey we need full course please! Basics to advance series
Hi can we make ETH coins while chatting ? Think about it…. I want to work with ye
Hi! Thanks for the tutorial! I wonder, would this be possible in a flutter app? A flutter chat dapp, I mean.
How well does webRTC scale? Can it support a billion connected nodes?
Thank you so much, that is so amazing!
I recently build a "chad" app – is what i heared
0:23 dope
says while hosting on firebase
Today, I was thinking that, maybe someday, I wanted to build an application based on blockchain. I think about a blockchain as a giant kurbernete cluster where millions (could be billions) machines connected each other as nodes. And I don't worry about managing the whole cluster/blockchain myself. :DD
jesus christ, dude.. in 15 minutes? you are the best of the best. period.
Dapp without a blockchain?
7:00 That double whitespace is triggering my OCD so hard XD
What you do for the dev world…is just amazing. THANK YOU. Please keep making (some) free content. I promise I'll get a few months of your pro thing soon.
amazing another application that is extremally unsecure and serves no purpose but to find a purpose of blockchain that doesn't need a purpose for its speculative price but rather more idiots willing to make money.
Holochain
i logged in with one device sent a message on the website and signed up in another device but couldnt see the message
As a first time investor in crypto I started trading with Mr Potterst0cks with just a thousand bucks. my portfolio is worth much more that now within just weeks of trading with him I really appreciate you man
As a first time investor in crypto I started trading with Mr Potterst0cks with just a thousand bucks. my portfolio is worth much more that now within just weeks of trading with him I really appreciate you man
Do this chat app support real-time messaging?