Truffle Box for Angular is a quick-and-easy way to get your Dapp on the road with Truffle and Angular
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 22 commits ahead of Perseverance:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.travis
contracts
e2e
migrations
src
test
.angular-cli.json
.editorconfig
.gitignore
.jsbeautifyrc
.travis.yml
LICENSE
NOTICE
README.md
box-img-lg.png
box-img-sm.png
karma.conf.js
package-lock.json
package.json
protractor.conf.js
truffle-box.json
truffle.js
tsconfig.json
tslint.json

README.md

This is a fork from Quintor:

I've added:

  • SCSS instead of CSS
  • Upgraded the typescript as I love async/await
  • Added bootstrap 3
  • Added Axios

Everything below is the same as in Quintors Box

Truffle Box for Angular

This Truffle Box provides a base for working with the Truffle Framework and Angular. It provides a basic working example of the MetaCoin contracts with Angular components. This project is generated with Angular CLI.

Building

  1. Install truffle, Angular CLI and an Ethereum client. If you don't have a test environment, we recommend Ethereum TestRPC
npm install -g truffle
npm install -g @angular/cli
npm install -g ethereumjs-testrpc
  1. Download the box.
truffle unbox LimelabsTech/angular-truffle-box
  1. Run your Ethereum client. For TestRPC:
testrpc

Note the mnemonic 12-word phrase printed on startup, you will need it later.

  1. Compile and migrate your contracts.
truffle compile && truffle migrate

Running

  1. Run the app using Angular CLI:
ng serve

The app is now served on localhost:4200

  1. Connect to it by opening it in your browser and configuring MetaMask with the 12-word phrase from TestRPC.

  2. Send MetaCoins!

Testing

  1. Running the Angular component tests:
ng test
  1. Running the Truffle tests:
truffle test
  1. Running Protactor end-to-end tests
ng e2e

Releasing

Using the Angular CLI you can build a distributable of your app. Will be placed in dist/

ng build

FAQ

  • Where can I find more documentation?

This Truffle box is a union of Truffle and an Angular setup created with Angular CLI. For solidity compilation and Ethereum related issues, try the Truffle documentation. For Angular CLI and typescript issues, refer to the Angular CLI documentation