Skip to content

Latest commit

 

History

History
34 lines (25 loc) · 1.27 KB

File metadata and controls

34 lines (25 loc) · 1.27 KB

Build React Projects with Waf

Introduction

We show that Waf provides an alternative to Gulp for front-end development and automation. Our example uses Waf to automate build tasks for React components, including compiling, minifying, installing, and unit testing them. The results are served from a Rust web server, which is also built with Waf.

Prerequisites

Download and install Vagrant and VirtualBox.

Configuration

Run the following command from inside the vagrant directory to configure a virtual machine that contains all the dependencies needed to run this example.

vagrant up

Usage

You can access the virtual machine over SSH by running the following command.

vagrant ssh

We use Waf to compile, minify, install, and unit test React components. Run the following commands from inside your virtual machine to perform these actions.

cd /opt/project/workspace
python waf configure build install test

Destruction

Run the following command from inside the vagrant directory to destroy your virtual machine.

vagrant destroy