- [10m] ☀️ Warm Up: Make Sure Environment is Set Up
- [20m] 💻 Activity: Smart Contracts vs DApps
- [10m] 💬 Discuss: Smart Contracts vs DApps
- [20m] 💻 Activity: Architecture Distributions
- [30m] 📚 TT: DApps Overview
- [10m] 💻 Activity: Actualizing Advantages
- [10m] 📚 TT: DApp Advantages
- [05m] 📚 TT: Architecture Diagram
- [05m] 🌃 Wrap Up: Takeaways
- 📚 Resources & Credits
In breakout rooms, double check that both you and your partner can successfully run brownie compile
and brownie run token
commands in the starter project from last class.
Watch Difference between DApps and Smart Contracts? Programmer explains. and answer the following questions:
- In your notebook, list everything you know about Smart Contracts and DApps.
- How are the two terms similar?
- How are they different?
When you're done, post your list on Slack in the #bew2-4-dapps
channel.
Ask students to share answers and discuss.
Most projects require the following categories in order to be considered full stack applications:
- Backend
- Frontend
- Data storage
- Inter-process messaging
- Name resolution
Each could be somewhat centralized or somewhat decentralized.
- a frontend web app that runs on a centralized server, or a mobile app
- backend and data storage on private servers / proprietary databases, or you could use a smart contract and P2P storage
Discuss the answers to the following challenge questions in breakout rooms:
- Which of these categories are commonly decentralized?
- For each category, provide at least one example of each that occurs in real life...
- a centralized example
- a decentralized example
When you're done, post your list on Slack in the #bew2-4-dapps
channel.
Note
Web 2.0 began when Web users started to drastically change the way they were using the Web on a day-to-day basis. The main trends that shaped Web 2.0 include content sharing, creativity, segmentation, social components, and a large move from static web sites and tools to more dynamic ones.
The creators of Ethereum had a grand vision --- one beyond smart contracts. They wanted to invent a new web full of decentralized applications, and named this concept web3
.
- Smart Contracts are a way to decentralize the controlling logic and payment functions of applications.
- Web3 DApps: are web applications that are mostly or completely decentralized. They decentralize all other aspects of an application: storage, messaging, naming, etc using smart contracts on the backend.
Give examples of when a programmer might be interested in developing an application that is...
- Resilient
- Transparent
- Censorship Resistant
DApps provide several advantages over traditional centralized architectures.
Because the business logic is controlled by a smart contract, a DApp backend will be fully distributed and managed on a blockchain platform.
Unlike an application deployed on a centralized server, a DApp will have no downtime and will continue to be available as long as the platform is still operating.
The on-chain nature of a DApp allows everyone to inspect the code and be more sure about its function. Any interaction with the DApp will be stored forever in the blockchain.
As long as a user can access or run a node on the Ethereum network, they can use DApps without interference from any centralized control.
No service provider, or even the owner of the smart contract, can alter the code once it is deployed on the network.
- DApps are the culmination of the Ethereum vision; explored in the earliest design phases of Ethereum.
- Many apps call themselves “DApps” today --- most are NOT 100% decentralized.
- Today, it's 100% possible to write applications that are nearly entirely decentralized.
- In the future, as the technology matures further, more and more of our applications can be decentralized, resulting in a more resilient, censorship-resistant, and free web.
- Mastering Ethereum: Building Smart Contracts and DApps; Andreas M. Antonopoulos. Published 2019.