project screenshot 1
project screenshot 2
project screenshot 3

SacredEx

SacredEx aims to tackle some of the fundamental problems that our society faces, and also aims to make the users of the dex healthier, happier and more knowledgeable. Our motto? Don’t just make money, make a difference.

SacredEx

Created At

HackMoney 2022

Project Description

TL:DR

SacredEx aims to tackle some of the fundamental problems that our society faces, and also aims to make the users of the dex healthier, happier and more knowledgeable.

Our motto? Don’t just make money, make a difference.

Goal

Dexes have the potential to become major financial powers. At the time of this writing, the Uniswap TVL is at almost 6 billion dollars. Our goal is to have each million added to SacredEx improve the lives of those using it and of the society at large, while also making the users of the Dex money.

How?

First, the coins listed on SacredEx need to satisfy some conditions. All of them will be created as sacred contracts - a sacred contract is a contract that at its creation states that “this contract is built for the betterment of all” in its code (the contract is currently in development).

Second, all of the coins need to be sacred coins. Sacred coins are contracts built with guidelines in mind, intended for the user of the coin. For example, the guideline of the gratitude coin is Every time you buy or sell the coin, you should think about something that you’re grateful for. These guidelines are stored in the coin’s contract, and the SacredEx retrieves them and places them on the website, for all to see.

Sacred coins are built with accomplishing a goal in mind - for example, the intention of the gratitude coin is to spread the practice of gratitude; The intention of the General Peace Token is to foster peace in the world.

To that end, sacred coins have unique functionalities that aim to help reach their stated goal. For example, the gratitude coin allows people to write a message of gratitude when they buy or sell the coin. SacredEx accommodates those unique functionalities within the decentralized exchange. So in the case of the gratitude coin, the user has the option of writing a message of gratitude. That message then not only gets published on the blockchain, but it also goes on social media websites (currently Twitter) to help inspire others to think about what they are grateful for.

And finally, a portion of the fee that the exchange charges for a transaction will go towards charities that help to accomplish the coin’s goals, via Endaoment. So for example, a portion of the fee acquired when buying or selling the General Peace Token will go towards The World Peace Game Foundation and PeaceDirect - both of which aim to help solve conflicts and bring about world peace. (Feature currently in development)

That way, the more users buy a specific coin, the more resources goes towards accomplishing its goal.

Eventually, SacredEx aims to make the process of choosing the charities that the fees will go to decentralized.

What does this mean?

It means that when you are investing on SacredEx you are not just making money, you are making a difference.

Every coin that you invest in is aimed towards the betterment of all, or towards enriching the lives of the coin users.

There is still opportunity to make money, of course - a coin’s value may grow via your investment and or spreading the popularity of the coin, but on SacredEx, this money making opportunity is coupled with the opportunity of doing good. To have one of these coins gain popularity means to raise awareness around the topic that it addresses, via its stated goal and via the messages that people write, and to divert resources in that direction via the dex exchange fee. So it is a win-win-win.

It has been said that love of money is the root of all evil. On SacredEx, we aim to show that with the help of blockchain technology, love of money can become the root of all good.

How it's Made

he major technologies used:

Frontend:

React (with Redux and styled components) for the frontend.

Web3-modal for the wallet connection, with Coinbase Wallet, WalletConnect and Metamask as wallet options.

React-awesome-spinners for the cool loading modal.

React-icons for icons.

Smart Contracts:

Hardhat as the development suite.

Ethersjs as the web3 library.

Mocha & chai for testing.

Uniswap V1 as inspiration for the smart contract logic for the exchange.

Openzeppelin for the erc20 contracts.

Polygon Testnet as the blockchain for the application.

Fleek to deploy the application to IPFS.

I did a lot of hackable things during the project. To validate all of the user interactions I used the React useEffect hook in ways that I hadn’t done before. I also made extensive use of styled components with props to disable the frontend when the transactions were being run.

I used coinbase wallet a lot during development. At some point the Metamask wallet was being incredibly slow while the coinbase wallet was fast and seamless, so I stopped using Metamask for the dev work altogether. But the coinbase wallet does have quirks, that I am planning to share with the coinbase team after spending some quality time with it these past couple of weeks.

It was interesting to see how focused I became during the project. I would wake up in the morning and think of solutions to problems that were raised the day before. It was great. I spent much of my waking day working on this, and I learned a great deal about web3 with react, and I also saw how much I love doing this.

And I couldn’t believe just how easy it was to deploy the website to IPFS using fleek. Wow! And the IPFS speed is not bad at all.

This was a highly educational experience.

background image mobile

Join the mailing list

Get the latest news and updates