Coder Social home page Coder Social logo

algorand-mono's Introduction

Hyperverse logo

Getting Started

npm i

Developing.

npm run start

Compiling for production.

npm run build

Lessons Learned

#1

algosdk doesn't play nice with create-react-app because react-scripts v5.0.0 uses Webpack 5 which doesn't polyfill crypto and other Node packages.

Change your react-scripts dependency to 4.0.3.

"dependencies": {
  "react-scripts": "4.0.3"
}

This unfortunately breaks your hot-reload and you need to add the following dev dependency to override the broken one.

"devDependencies": {
  "react-error-overlay": "6.0.9"
}

After changing your package.json delete node_modules and package-lock.json and reinstall everything.

npm install

source source

#2

While in development (localhost) WalletConnect won't work without a https connection.

You can either fix this by using ngrok as a reverse proxy.

ngrok http -region eu 3000

Or you can generate your own certificate.

  1. Install mkcert on your operating system – instructions.
  2. $ mkcert -install – generate a local certificate authority.
  3. $ mkcert localhost – generate a certificate (if you want local network access, use host IP within local network, I.e. 192.168.X.X).
  4. $ mkdir certificates – create folder to store certificate files (not part of code repository).
  5. $ mv localhost* certificates/ – move them there.

Then add two environment variables to start using your certificates locally.

HTTPS=true
SSL_CRT_FILE=certificates/192.168.X.X.pem
SSL_KEY_FILE=certificates/192.168.X.X-key.pem

You can add environment variables to your package.json by modifying your start script to "start": "HTTPS=true ....

source

algorand-mono's People

Contributors

jsheely avatar

Stargazers

spencer cap avatar

Watchers

Nik Kalyani avatar  avatar Jacob Tucker 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.