Skip to content

Refactor contract instance architecture #14

Description

@b1s0ndev

Context: Right now we instantiate the contract inside of the App.js and EventCreation.js files, but this is a bad design practice. Essentially we want to set this up so that we handle all of the contract instances in a state management library.

Tasks:

  • Create a new file called contract.js by creating a new ./services directory
  • We will want to require the contract instance in EventCreation.js (should be included at the top like: const {getInstance} = require('../services/contract')
  • Inside contract.js should consist of all the necessary getters and setters for the contract and account instances.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions