Code Monkey home page Code Monkey logo

mantle-demo's Introduction

mantle-demo

What is mantle-demo?

An example app highlighting how to use Mantle's asymmetric and symmetric encryption/decryption capabilities, mnemonic/account generation and management, and more.

Features

  • React frontend responsible for encrypting data, generating user accounts and communicating with API
  • API component responsible for communicating with our blockchain via web3 and storing contract information
  • Contract component reponsible for compilation and deployment of "Notes" and "Users" contracts

Setup

docker-compose

To deploy the app to docker locally:

From project root(/):

docker-compose build
docker-compose up

The application will start up but your contracts will not be deployed to your parity instance, so HTTP requests will fail until you deploy the contracts.

From /contracts:

npm i
npm run compile
npm run deploy

Unlike local development, data should persist while the parity volume (defined in docker-compose.yml) still exists.

The API server will start on port 3000 and react app on port 3001

Local

To set up the demo locally, perform the following actions:

From /api:

npm i

From /contracts:

npm i
npm run compile
npm run parity
npm run deploy (Deploys contracts to your running parity node)

From /react:

npm i

From project root(/):

npm i
npm start

The API server will start on port 3000 and react app on port 3001

Available API routes:

GET http://localhost:3000/api/users
GET http://localhost:3000/api/notes
POST http://localhost:3000/api/notes

mantle-demo's People

Watchers

 avatar  avatar  avatar  avatar  avatar

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.