Skip to content

jart/web_library_example

Repository files navigation

Web Library Example Build Status

This repository demonstrates how to bootstrap a web application, like TensorBoard, that uses Bazel, Polymer, TypeScript, D3, Plottable, ThreeJS, etc.

First you must install the latest Bazel. Then you may clone this repository and cd into the directory.

To bring up the vz_heatmap documentation in a raw sources development server:

bazel run //web_library_example/vz_heatmap:index

Here is a TypeScript version of the same thing:

bazel run //web_library_example/vz_heatmap_ts:index

To bring up a development web server with the vulcanized HTML binary:

bazel run //web_library_example:index

You'll notice that every single import, script, and stylesheet was inlined into one file. You can deploy it to production on a GCS bucket as follows:

bazel build //web_library_example:index
gsutil cp -a public-read -Z bazel-bin/web_library_example/index.html gs://my-bucket

To build everything:

bazel build //web_library_example/...