Coder Social home page Coder Social logo

deltaversedao / fractal-metafactory Goto Github PK

View Code? Open in Web Editor NEW

This project forked from decentdao/fractal-metafactory

0.0 0.0 1.0 1.11 MB

Decent DAO fractal metafactory DAO deployer metafactory

License: The Unlicense

Shell 0.70% JavaScript 0.50% TypeScript 35.87% Solidity 62.93%

fractal-metafactory's Introduction

Fractal-Metafactory

Architecture

Metafactory deploys MVD, Governor Contract, Treasury, Token, and any other associated modules.

Metafactory.sol

The Metafactory contract acts as a factory proxy which quickly sets up a MVD and attaches any modules that a user would like to include. It creates permissions in the access control and removes renounces its role at the end of setup

Local Setup & Testing

Clone the repository:

git clone ...

Lookup the recommended Node version to use in the .nvmrc file and install and use the correct version:

nvm install 
nvm use

Install necessary dependencies:

npm install

Add .env values replacing the private key and provider values for desired networks

cp .env.example .env

Compile contracts to create typechain files:

npm run compile

Run the tests

npm run test

Deploy Contract to

npx hardhat deploy --network <network>

Local Hardhat deployment

To deploy the base Fractal contracts open a terminal and run:

npx hardhat node

This will deploy the following contracts and log the addresses they were deployed to:

  • MetaFactory

Deploys all other contracts for testing purposes

Creating a module

Each module should inherit the MVD contracts to include:

  • moduleBase.sol
  • IModuleBaseFactory.sol

Install the npm package

npm i fractal-contracts-package

Including un-compiled contracts within typechain-types. Follow theses steps hardhat plug-in https://www.npmjs.com/package/hardhat-dependency-compiler

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.