Introduction

This is a demo book.

build

  1. gitbook install
  2. gitbook serve
  3. # view http://localhost:4000

demo

demo 1: typescript

  1. class Polygon {
  2. constructor(height, width) {
  3. this.height = height;
  4. this.width = width;
  5. }
  6. get area() {
  7. return this.height * this.width;
  8. }
  9. }

demo 2: javascript

  1. function foo(bar) {
  2. var a = 42,
  3. b = "Prism";
  4. return a + bar(b);
  5. }