April 2017
Intermediate to advanced
266 pages
7h 4m
English
Truffle comes with an in-built web server. This web server simply serves the files in the build directory with a proper MIME type set. Apart from this, it's not configured to do anything else.
To run the web server, run this command:
truffle serve
The server runs on port number 8080 by default. But you can use the -p option to specify a different port number.
Similar to truffle watch, this web server also watches for changes in the contracts directory, the app directory, and the configuration file. When there's a change, it recompiles the contracts and generates new artifacts files and then rebuilds the client. But it doesn't run migrations and tests.
As the truffle-default-builder places the final deployable code in the ...