This is a hackathon project built at ETHWarsaw by @dennis_zoma, @mike1third, @cryptoneur_eth, and @atris_eth.
The repository is archived and the mainnet version will be open-sourced on launch.
# Install pnpm
npm i -g pnpm
# Install dependencies
pnpm install
# Copy & fill environments
cp packages/frontend/.env.local.example packages/frontend/.env.local
# cp packages/contracts/.env.example packages/contracts/.env
I reommend developing in VSCode by opening the workspace file located at .vscode/azns.code-workspace
and installing recommended plugins listed in .vscode/extensions.json
.
# Generate contract-types, start local hardhat node, and start frontend with turborepo
pnpm dev
# Only start frontend
pnpm frontend:dev
We are deploying to the Permaweb via Arweave, Bundlr, and arkb (see https://docs.arweave.org/developers/tools/textury-arkb).
# 1. Create a Bundlr Wallet & load it with some tokens
# 2. Place a `wallet.json` with your private key into `./packages/frontend/`
# 3. Inside of the `frontend` package execute
pnpm run deploy
Web3 and the overall Crypto ecosystem need to strive for simplicity and the best user experience possible. One significant improvement to achieve this goal has been the introduction of the Ethererum domains by the Ethereum Name Service (ENS). Thereby, the representation of the wallet address consisting of arbitrary characters is abstracted away with a simple domain identifier.
Aleph Zero is an L1 blockchain whose technical specifications offer a new level of user experience with near-zero transaction costs and sub-second transaction finality. We believe that we can enhance the UX even more by introducing our decentralized .azero domains.
This innovation will make it easier for users to navigate the Aleph Zero ecosystem. The simplicity of domain names reduce human error compared to inputting long addresses. Sending a transaction to the wrong .azero domain is less likely than with an address in hexadecimal representation. This reduces the anxiety of new users interacting with the web3 ecosystem. Furthermore, using our domains makes sending payments and any other interactions more efficient and convenient.
We deployed Rust-based smart contracts on Aleph Zero testnet that contain a decentralized domain registry as well as an attached metadata storage. Our https://azero.domains dApp leverages those contracts and gives the user the ability to search, buy, and manage domains. The frontend interacting with the smart contracts is deployed on the Permaweb network by Arweave for maximum censorship resistance.
The user journey with the Azero Domains app is as follows. First, the user checks if his desired domain is available with the search function. If yes, he can purchase & claim the domain in just one click. If the user has not yet connected his wallet to the dApp, he will be prompted to do so. After a successfull purchase with $TAZERO tokens, the user's new domain is shown in his dashboard. He now has the option to 'manage' or 'release' any possessed domain. Managing the domain allows for storing metadata such as social handles (e.g. Twitter, Discord, Telegram, or Lens Protocol), personal website URL or any other arbitrary data. The dApp also provides a shareable, dynamic visual representation of the new domain and the added social handles in form of a contact card. This feature lets the user share his .azero domain as a contact card.
The frontend is written in Typescript with Next.js
used as the framework, and tailwindcss
as well as daisyUI
for styling. For the contract interactions we use polkadot.js
which unfortunately isn't ready for server-side rendered frameworks (see Challenges we ran into). For the deployment, we statically export the Next.js app and then upload it to the Arweave Permaweb via arkb
& bundlr
.
We used the ink! eDSL by Parity for Substrate-compatible smart contracts. Since ink! is just Rust with some macros and a WASM build target, even though we didn't have prior experience building SCs in Rust, we were able to quickly get productive by leveraging existing Rust infra and community.
- As stated above, we ran into multiple issues related to
polkadot.js
not being ready for server-side frameworks (i.e.Next.js
). After quite some time we found a workaround by dynamically importing@polkadot/extension-dApp
whenever we do contract interactions on the client side. In our opinion this either should be fixed on thepolkadot.js
side, or by a simple wrapper package that makes it work for others with a single import. - Then, we had some initial struggles with deploying our static bundle to the Arweave Permaweb. But with the help of Sophie and users from their discord, we figured out that import urls should be dynamic instead of static. And this can be done by adding
assetPrefix: './'
in the config.
- Building and deploying a working and well-tested naming and digital profile service in the span of one day.
- Going from beginner Rust knowledge to being productive with ink!
- How to write smart contracts for Substrate with ink!
- How to leverage existing Rust infrastructure for testing and deploying ink! smart contracts
- How to interface with the chain using Polkadot.js, including both reads and writes
- How to deploy a static frontend to the Arweave Permaweb
After the successfull testnet deplyoment during the hackathon, we are awaiting the smart contract mainnet deployment by the Aleph Zero team to ship azero.domains to mainnet. Until then, we will be focussing on creating awareness, creating a community around the project and attracting testnet users to collect feedback and improve the user experience. Further, we will be exploring the feasibility of adding additional features to our dApp to increase the overall utility. Creating a DAO for a decentralized governance and an on-chain governed treasury fueled by revenues from royalties to fund public goods and ecosystem development is also a feasable option for the future.
Potential future features could include:
- NFT implementation of domain and visual implementation via permeweb by Arweave
- Feature-rich marketplace with fixed asked price, auctions, dutch auctions and bundled transactions
- Wallet features and direct domain-to-domain transactions
- Contact book for further increase in UX and convenience
Potential future tech improvements:
- Mainnet deployment
- Upgradable smart contracts
- Mobile optimized version